|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.tubs.cs.sc.casim.TransitionRule
class TransitionRule describing one transition rule in the table
StateSetDefinition
,
TableState
,
Serialized FormConstructor Summary | |
protected |
TransitionRule()
Construction constructs an empty TransistionRule all values must be set using appropriate methods |
Method Summary | |
protected boolean |
doesNeighborhoodMatch(de.tubs.cs.sc.casim.State[] states)
for simulation returns true, if all neighbors match to the rule returns false, if one or more neighbors mismatch |
int |
getNeighbor(int i)
gets the i's neighbor |
int |
getNewState()
returns the new state |
int |
getNrOfNeighbors()
|
int |
getState()
returns the current state |
void |
setNeighbor(int i,
int iState)
sets the i's neighbor, if the new neighbor is outside the array of neighbors, the array will be enlarged |
void |
setNewState(int iNewState)
sets the new state |
void |
setState(int iState)
sets the current state |
java.lang.String |
toString()
converts the rule to a human readable string |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
protected TransitionRule()
Method Detail |
public int getState()
public int getNewState()
public void setState(int iState)
public void setNewState(int iNewState)
public int getNrOfNeighbors()
public int getNeighbor(int i)
public void setNeighbor(int i, int iState)
public java.lang.String toString()
toString
in class java.lang.Object
protected boolean doesNeighborhoodMatch(de.tubs.cs.sc.casim.State[] states)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |