Class DroolsConstraintStreamScoreDirectorFactory<Solution_,Score_ extends Score<Score_>>
- java.lang.Object
-
- org.optaplanner.core.impl.score.director.AbstractScoreDirectorFactory<Solution_,Score_>
-
- org.optaplanner.core.impl.score.director.stream.AbstractConstraintStreamScoreDirectorFactory<Solution_,Score_>
-
- org.optaplanner.core.impl.score.director.stream.DroolsConstraintStreamScoreDirectorFactory<Solution_,Score_>
-
- All Implemented Interfaces:
InnerScoreDirectorFactory<Solution_,Score_>
,ScoreDirectorFactory<Solution_>
public final class DroolsConstraintStreamScoreDirectorFactory<Solution_,Score_ extends Score<Score_>> extends AbstractConstraintStreamScoreDirectorFactory<Solution_,Score_>
-
-
Field Summary
-
Fields inherited from class org.optaplanner.core.impl.score.director.AbstractScoreDirectorFactory
assertClonedSolution, assertionScoreDirectorFactory, initializingScoreTrend, logger, solutionDescriptor
-
-
Constructor Summary
Constructors Constructor Description DroolsConstraintStreamScoreDirectorFactory(SolutionDescriptor<Solution_> solutionDescriptor, ConstraintProvider constraintProvider, boolean droolsAlphaNetworkCompilationEnabled)
DroolsConstraintStreamScoreDirectorFactory(SolutionDescriptor<Solution_> solutionDescriptor, KieBaseDescriptor<Solution_> kieBaseDescriptor, boolean droolsAlphaNetworkCompilationEnabled)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <Solution_>
KieBaseDescriptor<Solution_>buildKieBase(SolutionDescriptor<Solution_> solutionDescriptor, ConstraintProvider constraintProvider, boolean droolsAlphaNetworkCompilationEnabled)
DroolsConstraintStreamScoreDirector<Solution_,Score_>
buildScoreDirector(boolean lookUpEnabled, boolean constraintMatchEnabledPreference)
LikeInnerScoreDirectorFactory.buildScoreDirector()
, but optionally disablesConstraintMatch
tracking and look up for more performance (presuming theScoreDirector
implementation actually supports it to begin with).Constraint[]
getConstraints()
boolean
isDroolsAlphaNetworkCompilationEnabled()
SessionDescriptor<Score_>
newConstraintStreamingSession(boolean constraintMatchEnabled, Solution_ workingSolution)
-
Methods inherited from class org.optaplanner.core.impl.score.director.AbstractScoreDirectorFactory
assertScoreFromScratch, buildScoreDirector, getAssertionScoreDirectorFactory, getInitializingScoreTrend, getScoreDefinition, getSolutionDescriptor, isAssertClonedSolution, setAssertClonedSolution, setAssertionScoreDirectorFactory, setInitializingScoreTrend
-
-
-
-
Constructor Detail
-
DroolsConstraintStreamScoreDirectorFactory
public DroolsConstraintStreamScoreDirectorFactory(SolutionDescriptor<Solution_> solutionDescriptor, ConstraintProvider constraintProvider, boolean droolsAlphaNetworkCompilationEnabled)
-
DroolsConstraintStreamScoreDirectorFactory
public DroolsConstraintStreamScoreDirectorFactory(SolutionDescriptor<Solution_> solutionDescriptor, KieBaseDescriptor<Solution_> kieBaseDescriptor, boolean droolsAlphaNetworkCompilationEnabled)
-
-
Method Detail
-
buildScoreDirector
public DroolsConstraintStreamScoreDirector<Solution_,Score_> buildScoreDirector(boolean lookUpEnabled, boolean constraintMatchEnabledPreference)
Description copied from interface:InnerScoreDirectorFactory
LikeInnerScoreDirectorFactory.buildScoreDirector()
, but optionally disablesConstraintMatch
tracking and look up for more performance (presuming theScoreDirector
implementation actually supports it to begin with).- Parameters:
lookUpEnabled
- true if aScoreDirector
implementation should track all working objects forScoreDirector.lookUpWorkingObject(Object)
constraintMatchEnabledPreference
- false if aScoreDirector
implementation should not doConstraintMatch
tracking even if it supports it.- Returns:
- never null
- See Also:
InnerScoreDirector.isConstraintMatchEnabled()
,InnerScoreDirector.getConstraintMatchTotalMap()
-
buildKieBase
public static <Solution_> KieBaseDescriptor<Solution_> buildKieBase(SolutionDescriptor<Solution_> solutionDescriptor, ConstraintProvider constraintProvider, boolean droolsAlphaNetworkCompilationEnabled)
-
newConstraintStreamingSession
public SessionDescriptor<Score_> newConstraintStreamingSession(boolean constraintMatchEnabled, Solution_ workingSolution)
-
getConstraints
public Constraint[] getConstraints()
- Specified by:
getConstraints
in classAbstractConstraintStreamScoreDirectorFactory<Solution_,Score_ extends Score<Score_>>
-
isDroolsAlphaNetworkCompilationEnabled
public boolean isDroolsAlphaNetworkCompilationEnabled()
-
-