com.tomgibara.pronto.state.impl
Class StateFactoryImpl
java.lang.Object
com.tomgibara.pronto.state.StateFactory
com.tomgibara.pronto.state.impl.StateFactoryImpl
public class StateFactoryImpl
- extends StateFactory
|
Method Summary |
|
emptyStateGraph()
Creates an empty state graph from which an editor is typically obtained
to build any required state graph. |
|
newEngine(StateGraph<S,L> graph,
StateActivator<S,L,P> activator)
Combines a graph and activator to form a new engine. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StateFactoryImpl
public StateFactoryImpl()
emptyStateGraph
public <S,L> StateGraph<S,L> emptyStateGraph()
- Description copied from class:
StateFactory
- Creates an empty state graph from which an editor is typically obtained
to build any required state graph.
- Specified by:
emptyStateGraph in class StateFactory
- Type Parameters:
S - the type of states the state graph editor will permitL - the type of labels the state graph editor will permit
- Returns:
- a state graph containing no states
newEngine
public <S,L,P> StateEngine<S,L,P> newEngine(StateGraph<S,L> graph,
StateActivator<S,L,P> activator)
- Description copied from class:
StateFactory
- Combines a graph and activator to form a new engine.
- Specified by:
newEngine in class StateFactory
- Type Parameters:
S - the type of states in the graphL - the type of labels in the graphP - the type of parameters accepted by the activator- Parameters:
graph - the graph of states and transitions permitted by the engineactivator - an object that can 'act' in response to state changes
- Returns:
- a new engine which can transition over the graph of states
subject to execution of the activator
Copyright © 2006-2007 Tom Gibara. All Rights Reserved.