|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object jopt.csp.spi.arcalgorithm.variable.VariableChangeBase jopt.csp.spi.arcalgorithm.variable.SetVariableBase
Method Summary | |
void |
addRequired(java.lang.Object value)
Adds a required value to the set |
void |
addRequired(java.util.Set values)
Adds a set of values to the required set |
void |
clearDelta()
Clears the delta set for this domain |
boolean |
equals(java.lang.Object obj)
Allows for equality comparisons between SetVariableBase objects |
SetDomain |
getDomain()
Returns domain for variable |
java.lang.String |
getName()
Returns name of node |
abstract SetNode |
getNode()
Retrieves node for an expression |
int |
getPossibleCardinality()
Returns possible cardinality |
java.util.Set |
getPossibleDeltaSet()
Returns the possible-delta set |
java.util.Set |
getPossibleSet()
Returns possible set of values in this variable's domain |
int |
getRequiredCardinality()
Returns required cardinality |
java.util.Set |
getRequiredDeltaSet()
Returns the required-delta set |
java.util.Set |
getRequiredSet()
Returns required set of values in this variable's domain |
int |
getSize()
Returns 1 + cardinality of possible - cardinality of required |
java.lang.Object |
getState()
Stores appropriate data for future restoration. |
int |
hashCode()
Returns a hash code based on this variable's name (if one exists) |
boolean |
isBound()
Returns true if this variable's domain is bound to a value |
boolean |
isInDomain(java.lang.Object val)
Returns true if value is in this variable's domain |
boolean |
isPossible(java.lang.Object value)
Returns true if the specified value is possible |
boolean |
isRequired(java.lang.Object value)
Returns true if the specified value is required |
void |
removePossible(java.lang.Object value)
Removes a value from the possible set |
void |
removePossible(java.util.Set values)
Removes a set of values from the possible set |
void |
restoreState(java.lang.Object state)
Restores variable information from stored data. |
void |
setName(java.lang.String name)
Sets name of node |
java.lang.String |
toString()
|
void |
updateGraph(NodeArcGraph graph)
Adds arcs representing this expression to the node arc graph |
Methods inherited from class jopt.csp.spi.arcalgorithm.variable.VariableChangeBase |
addVariableChangeListener, removeVariableChangeListener |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
Method Detail |
public java.lang.String getName()
getName
in interface jopt.csp.variable.CspSetVariable
public void setName(java.lang.String name)
setName
in interface jopt.csp.variable.CspSetVariable
public abstract SetNode getNode()
getNode
in interface SetVariable
public SetDomain getDomain()
getDomain
in interface SetVariable
public void updateGraph(NodeArcGraph graph)
updateGraph
in interface SetVariable
public int hashCode()
public final boolean equals(java.lang.Object obj)
obj
-
public final boolean isInDomain(java.lang.Object val)
isInDomain
in interface jopt.csp.variable.CspSetVariable
public final boolean isRequired(java.lang.Object value)
isRequired
in interface jopt.csp.variable.CspSetVariable
public final boolean isPossible(java.lang.Object value)
isPossible
in interface jopt.csp.variable.CspSetVariable
public final void addRequired(java.lang.Object value) throws jopt.csp.variable.PropagationFailureException
addRequired
in interface jopt.csp.variable.CspSetVariable
jopt.csp.variable.PropagationFailureException
public final void addRequired(java.util.Set values) throws jopt.csp.variable.PropagationFailureException
addRequired
in interface jopt.csp.variable.CspSetVariable
jopt.csp.variable.PropagationFailureException
public final void removePossible(java.lang.Object value) throws jopt.csp.variable.PropagationFailureException
removePossible
in interface jopt.csp.variable.CspSetVariable
jopt.csp.variable.PropagationFailureException
public final void removePossible(java.util.Set values) throws jopt.csp.variable.PropagationFailureException
removePossible
in interface jopt.csp.variable.CspSetVariable
jopt.csp.variable.PropagationFailureException
public final void clearDelta()
public final int getSize()
getSize
in interface jopt.csp.variable.CspSetVariable
public final int getPossibleCardinality()
getPossibleCardinality
in interface jopt.csp.variable.CspSetVariable
public final java.util.Set getPossibleDeltaSet()
public final java.util.Set getPossibleSet()
getPossibleSet
in interface jopt.csp.variable.CspSetVariable
public final int getRequiredCardinality()
getRequiredCardinality
in interface jopt.csp.variable.CspSetVariable
public final java.util.Set getRequiredDeltaSet()
public final java.util.Set getRequiredSet()
getRequiredSet
in interface jopt.csp.variable.CspSetVariable
public final boolean isBound()
isBound
in interface jopt.csp.variable.CspVariable
public java.lang.Object getState()
getState
in interface Storable
public void restoreState(java.lang.Object state)
restoreState
in interface Storable
public java.lang.String toString()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |