public class MatchingFrame extends VolatileTuple implements IModifiableTuple
Constructor and Description |
---|
MatchingFrame(int frameSize) |
MatchingFrame(MatchingFrame other)
Creates a copy of another matching frame; the two frames can be updated separately
|
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
get(int index) |
java.lang.Object[] |
getElements()
As the tuple is supposed to be immutable, do not modify the returned array.
|
int |
getSize() |
java.lang.Object |
getValue(int position)
Returns the value stored inside the matching frame.
|
void |
set(int index,
java.lang.Object value)
Sets the selected value for a tuple
|
void |
setValue(int position,
java.lang.Object value)
Sets the value of the variable at the given position.
|
boolean |
testAndSetValue(java.lang.Integer position,
java.lang.Object value) |
java.lang.String |
toString() |
equals, hashCode, toImmutable
doCalcHash, getDistinctElements, internalEquals, invertIndex, invertIndexWithMupliplicity, raiseIndexingError
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getDistinctElements, invertIndex, invertIndexWithMupliplicity, toImmutable
public MatchingFrame(int frameSize)
public MatchingFrame(MatchingFrame other)
other
- public java.lang.Object getValue(int position)
position
- java.lang.IndexOutOfBoundsException
- if position is negativejava.lang.IllegalArgumentException
- if the position is larger then the length of the framepublic void setValue(int position, java.lang.Object value)
position
- the position of the variable within the framevalue
- the value to be set for the variablepublic boolean testAndSetValue(java.lang.Integer position, java.lang.Object value)
public java.lang.String toString()
toString
in class AbstractTuple
public java.lang.Object get(int index)
public java.lang.Object[] getElements()
AbstractTuple
getElements
in interface ITuple
getElements
in class AbstractTuple
public void set(int index, java.lang.Object value)
IModifiableTuple
set
in interface IModifiableTuple