Package org.drools.planner.core.solution.director

Examples of org.drools.planner.core.solution.director.DefaultSolutionDirector


            } else {
                solver.setRandomSeed(DEFAULT_RANDOM_SEED);
            }
        }
        SolutionDescriptor solutionDescriptor = buildSolutionDescriptor();
        DefaultSolutionDirector solutionDirector = new DefaultSolutionDirector();
        solutionDirector.setSolutionDescriptor(solutionDescriptor);
        solutionDirector.setRuleBase(buildRuleBase());
        ScoreDefinition scoreDefinition = scoreDefinitionConfig.buildScoreDefinition();
        solutionDirector.setScoreDefinition(scoreDefinition);
        solver.setSolutionDirector(solutionDirector);
        Termination termination = terminationConfig.buildTermination(scoreDefinition, basicPlumbingTermination);
        solver.setTermination(termination);
        BestSolutionRecaller bestSolutionRecaller = new BestSolutionRecaller();
        solver.setBestSolutionRecaller(bestSolutionRecaller);
View Full Code Here


            } else {
                solver.setRandomSeed(DEFAULT_RANDOM_SEED);
            }
        }
        SolutionDescriptor solutionDescriptor = buildSolutionDescriptor();
        DefaultSolutionDirector solutionDirector = new DefaultSolutionDirector();
        solutionDirector.setSolutionDescriptor(solutionDescriptor);
        solutionDirector.setRuleBase(buildRuleBase());
        ScoreDefinition scoreDefinition = scoreDefinitionConfig.buildScoreDefinition();
        solutionDirector.setScoreDefinition(scoreDefinition);
        solver.setSolutionDirector(solutionDirector);
        Termination termination = terminationConfig.buildTermination(scoreDefinition, basicPlumbingTermination);
        solver.setTermination(termination);
        BestSolutionRecaller bestSolutionRecaller = new BestSolutionRecaller();
        solver.setBestSolutionRecaller(bestSolutionRecaller);
View Full Code Here

    }

    private LocalSearchSolverPhaseScope createLocalSearchSolverPhaseScope() {
        DefaultSolverScope solverScope = new DefaultSolverScope();
        LocalSearchSolverPhaseScope localSearchSolverPhaseScope = new LocalSearchSolverPhaseScope(solverScope);
        DefaultSolutionDirector solutionDirector = new DefaultSolutionDirector();
        solutionDirector.setScoreDefinition(new SimpleScoreDefinition());
        solverScope.setSolutionDirector(solutionDirector);
        solverScope.setWorkingRandom(new Random() {
            public double nextDouble() {
                return 0.2;
            }
View Full Code Here

    }

    private LocalSearchSolverPhaseScope createLocalSearchSolverPhaseScope() {
        DefaultSolverScope solverScope = new DefaultSolverScope();
        LocalSearchSolverPhaseScope localSearchSolverPhaseScope = new LocalSearchSolverPhaseScope(solverScope);
        DefaultSolutionDirector solutionDirector = new DefaultSolutionDirector();
        solutionDirector.setScoreDefinition(new HardAndSoftScoreDefinition());
        solverScope.setSolutionDirector(solutionDirector);
        solverScope.setBestScore(DefaultHardAndSoftScore.valueOf(-11, -200));
        localSearchSolverPhaseScope.setBestSolutionStepIndex(1000);
        LocalSearchStepScope lastLocalSearchStepScope = new LocalSearchStepScope(localSearchSolverPhaseScope);
        lastLocalSearchStepScope.setStepIndex(1000);
View Full Code Here

    }

    private LocalSearchSolverPhaseScope createLocalSearchSolverPhaseScope() {
        DefaultSolverScope solverScope = new DefaultSolverScope();
        LocalSearchSolverPhaseScope localSearchSolverPhaseScope = new LocalSearchSolverPhaseScope(solverScope);
        DefaultSolutionDirector solutionDirector = new DefaultSolutionDirector();
        solutionDirector.setScoreDefinition(new SimpleScoreDefinition());
        solverScope.setSolutionDirector(solutionDirector);
        solverScope.setWorkingRandom(new Random() {
            public double nextDouble() {
                return 0.2;
            }
View Full Code Here

TOP

Related Classes of org.drools.planner.core.solution.director.DefaultSolutionDirector

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.