public class ExternalizedSingletonInverseVariableSupply extends Object implements StatefulVariableListener<Object>, SingletonInverseVariableSupply
SingletonInverseVariableListener
.Modifier and Type | Field and Description |
---|---|
protected Map<Object,Object> |
inverseEntityMap |
protected VariableDescriptor |
sourceVariableDescriptor |
Constructor and Description |
---|
ExternalizedSingletonInverseVariableSupply(VariableDescriptor sourceVariableDescriptor) |
Modifier and Type | Method and Description |
---|---|
void |
afterEntityAdded(ScoreDirector scoreDirector,
Object entity) |
void |
afterEntityRemoved(ScoreDirector scoreDirector,
Object entity) |
void |
afterVariableChanged(ScoreDirector scoreDirector,
Object entity) |
void |
beforeEntityAdded(ScoreDirector scoreDirector,
Object entity) |
void |
beforeEntityRemoved(ScoreDirector scoreDirector,
Object entity) |
void |
beforeVariableChanged(ScoreDirector scoreDirector,
Object entity) |
void |
clearWorkingSolution(ScoreDirector scoreDirector) |
Object |
getInverseSingleton(Object value)
If entity1.varA = x then the inverse of x is entity1.
|
VariableDescriptor |
getSourceVariableDescriptor() |
protected void |
insert(ScoreDirector scoreDirector,
Object entity) |
void |
resetWorkingSolution(ScoreDirector scoreDirector) |
protected void |
retract(ScoreDirector scoreDirector,
Object entity) |
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
requiresUniqueEntityEvents
protected final VariableDescriptor sourceVariableDescriptor
public ExternalizedSingletonInverseVariableSupply(VariableDescriptor sourceVariableDescriptor)
public VariableDescriptor getSourceVariableDescriptor()
getSourceVariableDescriptor
in interface StatefulVariableListener<Object>
public void resetWorkingSolution(ScoreDirector scoreDirector)
resetWorkingSolution
in interface StatefulVariableListener<Object>
public void clearWorkingSolution(ScoreDirector scoreDirector)
clearWorkingSolution
in interface StatefulVariableListener<Object>
public void beforeEntityAdded(ScoreDirector scoreDirector, Object entity)
beforeEntityAdded
in interface VariableListener<Object>
scoreDirector
- never nullentity
- never nullpublic void afterEntityAdded(ScoreDirector scoreDirector, Object entity)
afterEntityAdded
in interface VariableListener<Object>
scoreDirector
- never nullentity
- never nullpublic void beforeVariableChanged(ScoreDirector scoreDirector, Object entity)
beforeVariableChanged
in interface VariableListener<Object>
scoreDirector
- never nullentity
- never nullpublic void afterVariableChanged(ScoreDirector scoreDirector, Object entity)
afterVariableChanged
in interface VariableListener<Object>
scoreDirector
- never nullentity
- never nullpublic void beforeEntityRemoved(ScoreDirector scoreDirector, Object entity)
beforeEntityRemoved
in interface VariableListener<Object>
scoreDirector
- never nullentity
- never nullpublic void afterEntityRemoved(ScoreDirector scoreDirector, Object entity)
afterEntityRemoved
in interface VariableListener<Object>
scoreDirector
- never nullentity
- never nullprotected void insert(ScoreDirector scoreDirector, Object entity)
protected void retract(ScoreDirector scoreDirector, Object entity)
public Object getInverseSingleton(Object value)
SingletonInverseVariableSupply
getInverseSingleton
in interface SingletonInverseVariableSupply
value
- never nullCopyright © 2006–2019 JBoss by Red Hat. All rights reserved.