com.tomgibara.pronto.state.impl
Class StateTransitionImpl<S,L>

java.lang.Object
  extended by com.tomgibara.pronto.state.impl.StateTransitionImpl<S,L>
All Implemented Interfaces:
StateTransition<S,L>

public class StateTransitionImpl<S,L>
extends java.lang.Object
implements StateTransition<S,L>


Constructor Summary
StateTransitionImpl(S source, L label, S target)
           
StateTransitionImpl(StateTransition<S,L> transition)
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 L getLabel()
          The label with which the transition is decorated.
 S getSource()
          The state away from which the transition is directed.
 S getTarget()
          The state towards which the transition is directed.
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StateTransitionImpl

public StateTransitionImpl(StateTransition<S,L> transition)

StateTransitionImpl

public StateTransitionImpl(S source,
                           L label,
                           S target)
Method Detail

getSource

public S getSource()
Description copied from interface: StateTransition
The state away from which the transition is directed.

Specified by:
getSource in interface StateTransition<S,L>
Returns:
the source of the transition, never null

getLabel

public L getLabel()
Description copied from interface: StateTransition
The label with which the transition is decorated.

Specified by:
getLabel in interface StateTransition<S,L>
Returns:
the label of the transition, never null

getTarget

public S getTarget()
Description copied from interface: StateTransition
The state towards which the transition is directed.

Specified by:
getTarget in interface StateTransition<S,L>
Returns:
the target of the transition, never null

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2006-2007 Tom Gibara. All Rights Reserved.