Class EntityDescriptor<Solution_>
java.lang.Object
org.optaplanner.core.impl.domain.entity.descriptor.EntityDescriptor<Solution_>
- Type Parameters:
Solution_
- the solution type, the class with thePlanningSolution
annotation
-
Constructor Summary
ConstructorDescriptionEntityDescriptor
(SolutionDescriptor<Solution_> solutionDescriptor, Class<?> entityClass) -
Method Summary
Modifier and TypeMethodDescriptionbuildInvalidVariableNameExceptionMessage
(String variableName) int
countReinitializableVariables
(Object entity) int
countUninitializedVariables
(Object entity) extractEntities
(Solution_ solution) Class<?>
long
getGenuineVariableDescriptor
(String variableName) Deprecated, for removal: This API element is subject to removal in a future version.long
getMaximumValueCount
(Solution_ solution, Object entity) long
getProblemScale
(Solution_ solution, Object entity) getShadowVariableDescriptor
(String variableName) getVariableDescriptor
(String variableName) boolean
boolean
boolean
boolean
boolean
hasNoNullVariables
(Object entity) boolean
hasVariableDescriptor
(String variableName) boolean
isEntityInitializedOrPinned
(ScoreDirector<Solution_> scoreDirector, Object entity) boolean
isInitialized
(Object entity) boolean
isMovable
(ScoreDirector<Solution_> scoreDirector, Object entity) void
linkEntityDescriptors
(DescriptorPolicy descriptorPolicy) void
linkVariableDescriptors
(DescriptorPolicy descriptorPolicy) boolean
matchesEntity
(Object entity) void
processAnnotations
(DescriptorPolicy descriptorPolicy) toString()
void
visitAllEntities
(Solution_ solution, Consumer<Object> visitor)
-
Constructor Details
-
EntityDescriptor
-
-
Method Details
-
getIsInitializedPredicate
Deprecated, for removal: This API element is subject to removal in a future version.PrefergetHasNoNullVariables()
.Using entityDescriptor::isInitialized directly breaks node sharing because it creates multiple instances of thisPredicate
.- Returns:
- never null, always the same
Predicate
instance toisInitialized(Object)
-
getHasNoNullVariables
-
processAnnotations
-
linkEntityDescriptors
-
linkVariableDescriptors
-
getSolutionDescriptor
-
getEntityClass
-
matchesEntity
-
hasEffectiveMovableEntitySelectionFilter
public boolean hasEffectiveMovableEntitySelectionFilter() -
getEffectiveMovableEntitySelectionFilter
-
getDecreasingDifficultySorter
-
getGenuineVariableNameSet
-
getGenuineVariableDescriptor
-
hasAnyGenuineVariables
public boolean hasAnyGenuineVariables() -
hasAnyGenuineListVariables
public boolean hasAnyGenuineListVariables() -
getGenuineVariableDescriptorList
-
getGenuineVariableCount
public long getGenuineVariableCount() -
getShadowVariableDescriptors
-
getShadowVariableDescriptor
-
getVariableDescriptorMap
-
hasVariableDescriptor
-
getVariableDescriptor
-
hasAnyDeclaredGenuineVariableDescriptor
public boolean hasAnyDeclaredGenuineVariableDescriptor() -
getDeclaredGenuineVariableDescriptors
-
getDeclaredShadowVariableDescriptors
-
getDeclaredVariableDescriptors
-
buildInvalidVariableNameExceptionMessage
-
extractEntities
-
visitAllEntities
-
getMaximumValueCount
-
getProblemScale
-
countUninitializedVariables
-
isInitialized
-
hasNoNullVariables
-
countReinitializableVariables
-
isMovable
-
isEntityInitializedOrPinned
- Parameters:
scoreDirector
- never nullentity
- never null- Returns:
- true if the entity is initialized or pinned
-
toString
-
getHasNoNullVariables()
.