net.groboclown.util.states.v1
Class StateCategory
java.lang.Object
|
+--net.groboclown.util.states.v1.StateCategory
- public class StateCategory
- extends Object
Creates new categories for State collections. Does not save the
created state objects. To save time, this creates both
States and Transitions, though it should only be used for one or
the other.
- Version:
- 0.9.0 Alpha
- Author:
- Matt Albrecht
Constructor Summary |
StateCategory(int maxStateCount)
Default Constructor |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
sync
private static final Object sync
categoryNum
private static int categoryNum
category
private int category
stateNum
private int stateNum
maxStates
private int maxStates
m_sync
private final Object m_sync
StateCategory
public StateCategory(int maxStateCount)
- Default Constructor
getNextState
public State getNextState()
- Creates a new unique State instance for this category.
getNextTransition
public Transition getNextTransition()
- Creates a new unique Transition instance for this category.
isOfCategory
public boolean isOfCategory(State s)
- Checks if the given state is of this category.
getMaximumStateCount
public int getMaximumStateCount()
getNextStateInt
private final int getNextStateInt()
getNextCategoryInt
private static final int getNextCategoryInt()
Written under the LGPL