Package org.jacop.core
Interface MutableVarValue
-
- All Known Implementing Classes:
BoundsVarValue,CircuitVarValue,Diff2VarValue,DisjointCondVarValue,MutableDomainValue
public interface MutableVarValueStandard mutable variable's value definition- Version:
- 4.8
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Objectclone()It clones the value of mutable variable.MutableVarValueprevious()It returns the earlier value of mutable variable.voidsetPrevious(MutableVarValue o)It replaces the earlier value of a mutable variable with value passed as parameter.voidsetStamp(int stamp)It sets the stamp of value of mutable variable.intstamp()It returns the stamp value of value of mutable variable.java.lang.StringtoString()It returns string representation of the current value of mutable variable.
-
-
-
Method Detail
-
clone
java.lang.Object clone()
It clones the value of mutable variable. It includes the stamp, pointer to earlier value, and current value of variable.- Returns:
- clone of the mutable variable value.
-
previous
MutableVarValue previous()
It returns the earlier value of mutable variable.- Returns:
- earlier value of mutable variable.
-
setPrevious
void setPrevious(MutableVarValue o)
It replaces the earlier value of a mutable variable with value passed as parameter.- Parameters:
o- the previous value for this mutable variable.
-
setStamp
void setStamp(int stamp)
It sets the stamp of value of mutable variable.- Parameters:
stamp- the new stamp of value of mutable variable
-
stamp
int stamp()
It returns the stamp value of value of mutable variable.- Returns:
- the current stamp of value of mutable variable.
-
toString
java.lang.String toString()
It returns string representation of the current value of mutable variable.- Overrides:
toStringin classjava.lang.Object
-
-