Class NQueensApp
- java.lang.Object
-
- org.optaplanner.examples.common.app.LoggingMain
-
- org.optaplanner.examples.common.app.CommonApp<NQueens>
-
- org.optaplanner.examples.nqueens.app.NQueensApp
-
public class NQueensApp extends CommonApp<NQueens>
For an easy example, look atNQueensHelloWorldinstead.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.optaplanner.examples.common.app.CommonApp
CommonApp.ExtraAction<Solution_>
-
-
Field Summary
Fields Modifier and Type Field Description static StringDATA_DIR_NAMEstatic StringSOLVER_CONFIG-
Fields inherited from class org.optaplanner.examples.common.app.CommonApp
DATA_DIR_SYSTEM_PROPERTY, dataDirName, description, iconResource, name, solutionBusiness, solverAndPersistenceFrame, solverConfigResource
-
Fields inherited from class org.optaplanner.examples.common.app.LoggingMain
logger
-
-
Constructor Summary
Constructors Constructor Description NQueensApp()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description org.optaplanner.persistence.common.api.domain.solution.SolutionFileIO<NQueens>createSolutionFileIO()Used for the unsolved and solved directories, not for the import and output directories, in the data directory.protected NQueensPanelcreateSolutionPanel()protected org.optaplanner.core.api.solver.SolverFactory<NQueens>createSolverFactory()protected org.optaplanner.core.api.solver.SolverFactory<NQueens>createSolverFactoryByApi()Unused alternative.protected org.optaplanner.core.api.solver.SolverFactory<NQueens>createSolverFactoryByXml()Normal way to create aSolver.static voidmain(String[] args)-
Methods inherited from class org.optaplanner.examples.common.app.CommonApp
createExtraActions, createSolutionBusiness, createSolutionExporters, createSolutionImporters, determineDataDir, getDataDirName, getDescription, getIconResource, getName, getSolverConfigResource, init, init, prepareSwingEnvironment
-
-
-
-
Field Detail
-
SOLVER_CONFIG
public static final String SOLVER_CONFIG
- See Also:
- Constant Field Values
-
DATA_DIR_NAME
public static final String DATA_DIR_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
main
public static void main(String[] args)
-
createSolverFactory
protected org.optaplanner.core.api.solver.SolverFactory<NQueens> createSolverFactory()
- Overrides:
createSolverFactoryin classCommonApp<NQueens>
-
createSolverFactoryByXml
protected org.optaplanner.core.api.solver.SolverFactory<NQueens> createSolverFactoryByXml()
Normal way to create aSolver.- Returns:
- never null
-
createSolverFactoryByApi
protected org.optaplanner.core.api.solver.SolverFactory<NQueens> createSolverFactoryByApi()
Unused alternative. A way to create aSolverwithout using XML.It is recommended to use
createSolverFactoryByXml()instead.- Returns:
- never null
-
createSolutionPanel
protected NQueensPanel createSolutionPanel()
- Specified by:
createSolutionPanelin classCommonApp<NQueens>
-
createSolutionFileIO
public org.optaplanner.persistence.common.api.domain.solution.SolutionFileIO<NQueens> createSolutionFileIO()
Description copied from class:CommonAppUsed for the unsolved and solved directories, not for the import and output directories, in the data directory.- Specified by:
createSolutionFileIOin classCommonApp<NQueens>- Returns:
- never null
-
-