com.hdcookbook.grin.io.builders
Class VisualRCHandlerCell.WallCell
java.lang.Object
com.hdcookbook.grin.io.builders.VisualRCHandlerCell
com.hdcookbook.grin.io.builders.VisualRCHandlerCell.WallCell
- Enclosing class:
- VisualRCHandlerCell
public static class VisualRCHandlerCell.WallCell
- extends VisualRCHandlerCell
Method Summary |
java.lang.String |
addState(java.util.Map<java.lang.String,java.lang.Integer> stateMap,
java.util.Set<java.lang.String> dupCheck,
java.util.Map<java.lang.String,VisualRCHandlerCell> cellMap)
Add the state referred to by this cell to the map of states. |
java.lang.String |
check()
Check that this cell is OK. |
VisualRCHandlerCell |
getRefersTo()
Get the cell that this cell refers to. |
java.lang.String |
getState()
Get the name of the state of this cell, or that this cell refers
to. |
int |
getStateNumber(java.util.Map<java.lang.String,java.lang.Integer> states,
java.lang.String stateFrom)
Get the integer number of this state within the states map when
navigating to this cell from the numbered state. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
getRefersTo
public VisualRCHandlerCell getRefersTo()
- Description copied from class:
VisualRCHandlerCell
- Get the cell that this cell refers to. Returns null if this
cell doesn't refer to another cell, e.g. because it's a state
or an .
- Specified by:
getRefersTo
in class VisualRCHandlerCell
addState
public java.lang.String addState(java.util.Map<java.lang.String,java.lang.Integer> stateMap,
java.util.Set<java.lang.String> dupCheck,
java.util.Map<java.lang.String,VisualRCHandlerCell> cellMap)
- Description copied from class:
VisualRCHandlerCell
- Add the state referred to by this cell to the map of states.
Calling this method multiple times on the same cell has no effect.
- Specified by:
addState
in class VisualRCHandlerCell
- Returns:
- null if OK, or an error message if not
getState
public java.lang.String getState()
- Description copied from class:
VisualRCHandlerCell
- Get the name of the state of this cell, or that this cell refers
to. Returns a synthetic value for activate, wall or null cells.
- Specified by:
getState
in class VisualRCHandlerCell
getStateNumber
public int getStateNumber(java.util.Map<java.lang.String,java.lang.Integer> states,
java.lang.String stateFrom)
throws java.io.IOException
- Description copied from class:
VisualRCHandlerCell
- Get the integer number of this state within the states map when
navigating to this cell from the numbered state.
- Specified by:
getStateNumber
in class VisualRCHandlerCell
- Throws:
java.io.IOException
- if there's an error in the grid construction
check
public java.lang.String check()
- Description copied from class:
VisualRCHandlerCell
- Check that this cell is OK. This is called after the cell is
completely initialized.
- Specified by:
check
in class VisualRCHandlerCell
- Returns:
- null if OK, or an error message if not