public class TestVariable extends java.lang.Object implements InequalityTerm
Constructor and Description |
---|
TestVariable()
Construct a variable InequalityTerm with a null initial value.
|
TestVariable(java.lang.String value)
Construct a variable InequalityTerm with the specified
initial value.
|
Modifier and Type | Method and Description |
---|---|
void |
fixValue()
Disallow the value of this term to be set.
|
java.lang.Object |
getAssociatedObject()
Return the string value.
|
java.lang.String |
getInfo()
Return the information of this term.
|
java.lang.Object |
getValue()
Return the String value of this term.
|
InequalityTerm[] |
getVariables()
Return an array of size one.
|
void |
initialize(java.lang.Object e)
Set the value of this variable to the specified String.
|
boolean |
isSettable()
Return true.
|
boolean |
isValueAcceptable()
Check whether the current value of this term is acceptable,
and return true if it is.
|
void |
setName(java.lang.String name)
Set the name of this variable.
|
void |
setValue(java.lang.Object e)
Set the value of this variable to the specified String.
|
java.lang.String |
toString()
Override the base class to describe the variable.
|
void |
unfixValue()
Allow the value of this term to be changed.
|
public TestVariable()
public TestVariable(java.lang.String value)
value
- A Stringpublic void fixValue()
public java.lang.Object getAssociatedObject()
getAssociatedObject
in interface InequalityTerm
public java.lang.String getInfo()
public java.lang.Object getValue()
getValue
in interface InequalityTerm
setValue(Object)
public InequalityTerm[] getVariables()
getVariables
in interface InequalityTerm
public void initialize(java.lang.Object e) throws GraphActionException
initialize
in interface InequalityTerm
e
- a StringGraphActionException
- not thrownpublic boolean isSettable()
isSettable
in interface InequalityTerm
public boolean isValueAcceptable()
isValueAcceptable
in interface InequalityTerm
public void setName(java.lang.String name)
name
- The name of this variable.public void setValue(java.lang.Object e) throws GraphActionException
setValue
in interface InequalityTerm
e
- a StringGraphActionException
- not throwngetValue()
public java.lang.String toString()
toString
in class java.lang.Object
public void unfixValue()