|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--gumbo.util.state.AbstractStateSet | +--gumbo.interact.AbstractInteractorState
Constructor Summary | |
AbstractInteractorState()
Creates an instance, with a default InteractorPolicy. |
|
AbstractInteractorState(java.util.Collection init)
Creates an instance, with a default InteractorPolicy and an initial state, as allowed by the policy. |
|
AbstractInteractorState(java.util.Collection init,
StatePolicy policy)
Creates an instance, with a state policy and an initial state, as allowed by the policy. |
Method Summary | |
InteractorState |
getInteractorState()
Gets a singleton immutable view of this state, which is the current state value, resulting from the last reset or transit. |
StateSetField.EventIn |
getStateChangeIn()
Calls change() with the received state flags (a "masked change"). |
CollectionField.EventIn |
getStateResetIn()
Calls reset() with the received state flags. |
StateSetField.EventOut |
getStateResetOut()
Sends an immutable view of this state set when the state resets, whether or not the state value changed. |
CollectionField.EventIn |
getStateSetIn()
Calls set() with the received state flags. |
StateSetField.EventOut |
getStateTransitOut()
Sends an immutable view of this state set when the state transits (as a result of set(), change(), transit()), whether or not the state value changed. |
protected void |
stateReset()
Default implementation: Sends a reset out event. |
protected void |
stateTransit()
Default implementation: Sends a transit out event. |
Methods inherited from class gumbo.util.state.AbstractStateSet |
add, addAll, change, change, changeAll, clear, contains, containsAll, equals, getOldState, getStatePolicy, getStateSet, hashCode, isEmpty, iterator, remove, removeAll, reset, retainAll, set, size, toArray, toArray, toString, transit |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface gumbo.util.state.StateSet |
change, change, changeAll, getOldState, getStatePolicy, getStateSet, reset, set, transit |
Methods inherited from interface java.util.Set |
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray |
Constructor Detail |
public AbstractInteractorState()
public AbstractInteractorState(java.util.Collection init)
init
- The initial state (Object). None if null (initial
state will be empty unless the policy dictates otherwise).public AbstractInteractorState(java.util.Collection init, StatePolicy policy)
init
- The initial state (Object). None if null (initial
state will be empty unless the policy dictates otherwise).policy
- The state policy. None if null. Typically,
InteractorPolicy or a subclass.Method Detail |
protected void stateReset()
stateReset
in class AbstractStateSet
protected void stateTransit()
stateTransit
in class AbstractStateSet
public CollectionField.EventIn getStateResetIn()
InteractorState
getStateResetIn
in interface InteractorState
public CollectionField.EventIn getStateSetIn()
InteractorState
getStateSetIn
in interface InteractorState
public StateSetField.EventIn getStateChangeIn()
InteractorState
getStateChangeIn
in interface InteractorState
public StateSetField.EventOut getStateResetOut()
InteractorState
getStateResetOut
in interface InteractorState
public StateSetField.EventOut getStateTransitOut()
InteractorState
getStateTransitOut
in interface InteractorState
public InteractorState getInteractorState()
InteractorState
getInteractorState
in interface InteractorState
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |