com.ptc.windchill.upgrade.util.fsm
Class Transition

java.lang.Object
  extended bycom.ptc.windchill.upgrade.util.fsm.Reaction
      extended bycom.ptc.windchill.upgrade.util.fsm.Transition

public class Transition
extends Reaction

A reaction that will transition a StateMachine to an instance of a particular State.


Nested Class Summary
 
Nested classes inherited from class com.ptc.windchill.upgrade.util.fsm.Reaction
 
Field Summary
private  StateDefinition targetStateDefinition_
           
 
Fields inherited from class com.ptc.windchill.upgrade.util.fsm.Reaction
NOOP
 
Constructor Summary
Transition(StateDefinition target_state_definition)
          Transition
 
Method Summary
(package private)  void execute(Event event)
          A package internal method: performs the transition
(package private)  StateDefinition getTargetStateDefinition()
          A package internal method: the target of the transition
protected  boolean shouldTransitionProceed(Event event)
          Do some activity before a transition and decide if the transition should proceed or not.
 String toString()
          A simple description of the transition.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

targetStateDefinition_

private StateDefinition targetStateDefinition_
Constructor Detail

Transition

public Transition(StateDefinition target_state_definition)
Transition

Method Detail

getTargetStateDefinition

final StateDefinition getTargetStateDefinition()
A package internal method: the target of the transition


execute

final void execute(Event event)
A package internal method: performs the transition

Specified by:
execute in class Reaction

toString

public String toString()
A simple description of the transition.


shouldTransitionProceed

protected boolean shouldTransitionProceed(Event event)
Do some activity before a transition and decide if the transition should proceed or not. Override is optional, the default behavior is to return true. Overrides don't need to call super.shouldTransitionProceed(event).

Parameters:
event - the event causing the transition
Returns:
true to continue and perform the transition, false if the transition should not occur