guk.im
Class State

java.lang.Object
  extended byguk.im.State

public class State
extends Object

A state of the LocaleHandler FSM.


Field Summary
(package private)  boolean finalState
          Is this state final?
(package private)  Map transitionFunction
          The transition function for this state.
 
Constructor Summary
State()
          Default constructor; creates a non final state
State(boolean isFinal)
          Creates a new state
 
Method Summary
 Action addAction(Key key, Action action)
          Adds anew action to this state.
 Action getNext(Key key)
          Gets the action this state will activate for a given Key
 boolean hasNext()
          Has this state any actions?
 boolean isFinal()
          Is this state final?
 void setFinal(boolean pFinal)
          Sets the final attribute.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

transitionFunction

Map transitionFunction
The transition function for this state.


finalState

boolean finalState
Is this state final?

Constructor Detail

State

public State(boolean isFinal)
Creates a new state

Parameters:
isFinal -

State

public State()
Default constructor; creates a non final state

Method Detail

addAction

public Action addAction(Key key,
                        Action action)
Adds anew action to this state.

Parameters:
key -
action -

getNext

public Action getNext(Key key)
Gets the action this state will activate for a given Key

Parameters:
key -

isFinal

public boolean isFinal()
Is this state final?


hasNext

public boolean hasNext()
Has this state any actions?


setFinal

public void setFinal(boolean pFinal)
Sets the final attribute.

Parameters:
pFinal -