vtkKWStateMachineTransition Class Reference

a state machine transition. More...

#include <vtkKWStateMachineTransition.h>

Inheritance diagram for vtkKWStateMachineTransition:
Inheritance graph
[legend]
Collaboration diagram for vtkKWStateMachineTransition:
Collaboration graph
[legend]

List of all members.

Public Types

typedef vtkKWObject Superclass

Public Member Functions

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
virtual int IsComplete ()
virtual void Start ()
virtual void End ()

Static Public Member Functions

static
vtkKWStateMachineTransition
New ()
static int IsTypeOf (const char *type)
static
vtkKWStateMachineTransition
SafeDownCast (vtkObject *o)

Protected Member Functions

 vtkKWStateMachineTransition ()
 ~vtkKWStateMachineTransition ()

Protected Attributes

vtkIdType Id
vtkKWStateMachineStateOriginState
vtkKWStateMachineInputInput
vtkKWStateMachineStateDestinationState
char * EndCommand
char * StartCommand



enum  { StartEvent = 10000, EndEvent }
virtual vtkIdType GetId ()
virtual vtkKWStateMachineStateGetOriginState ()
virtual void SetOriginState (vtkKWStateMachineState *)
virtual vtkKWStateMachineInputGetInput ()
virtual void SetInput (vtkKWStateMachineInput *)
virtual vtkKWStateMachineStateGetDestinationState ()
virtual void SetDestinationState (vtkKWStateMachineState *)
virtual void SetStartCommand (vtkObject *object, const char *method)
virtual void InvokeStartCommand ()
virtual int HasStartCommand ()
virtual void SetEndCommand (vtkObject *object, const char *method)
virtual void InvokeEndCommand ()
virtual int HasEndCommand ()

Detailed Description

a state machine transition.

This class is the basis for a state machine transition. A state machine is defined by a set of states, a set of inputs and a transition matrix that defines for each pair of (state,input) what is the next state to assume.

Thanks:
This work is part of the National Alliance for Medical Image Computing (NAMIC), funded by the National Institutes of Health through the NIH Roadmap for Medical Research, Grant U54 EB005149. Information on the National Centers for Biomedical Computing can be obtained from http://nihroadmap.nih.gov/bioinformatics.
See also:
vtkKWStateMachine vtkKWStateMachineState vtkKWStateMachineTransition

Definition at line 39 of file vtkKWStateMachineTransition.h.


Member Typedef Documentation

Reimplemented from vtkKWObject.

Definition at line 44 of file vtkKWStateMachineTransition.h.


Member Enumeration Documentation

anonymous enum

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX

Enumerator:
StartEvent 
EndEvent 

Definition at line 137 of file vtkKWStateMachineTransition.h.


Constructor & Destructor Documentation

vtkKWStateMachineTransition::vtkKWStateMachineTransition (  )  [protected]
vtkKWStateMachineTransition::~vtkKWStateMachineTransition (  )  [protected]

Member Function Documentation

static vtkKWStateMachineTransition* vtkKWStateMachineTransition::New (  )  [static]

Reimplemented from vtkKWObject.

virtual const char* vtkKWStateMachineTransition::GetClassName (  )  [virtual]

Reimplemented from vtkKWObject.

static int vtkKWStateMachineTransition::IsTypeOf ( const char *  type  )  [static]

Reimplemented from vtkKWObject.

virtual int vtkKWStateMachineTransition::IsA ( const char *  type  )  [virtual]

Reimplemented from vtkKWObject.

static vtkKWStateMachineTransition* vtkKWStateMachineTransition::SafeDownCast ( vtkObject o  )  [static]

Reimplemented from vtkKWObject.

void vtkKWStateMachineTransition::PrintSelf ( ostream &  os,
vtkIndent  indent 
) [virtual]

Reimplemented from vtkKWObject.

virtual vtkIdType vtkKWStateMachineTransition::GetId (  )  [virtual]

Get id.

virtual vtkKWStateMachineState* vtkKWStateMachineTransition::GetOriginState (  )  [virtual]

Set/Get the state this transition is originating from.

virtual void vtkKWStateMachineTransition::SetOriginState ( vtkKWStateMachineState  )  [virtual]

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX

virtual vtkKWStateMachineInput* vtkKWStateMachineTransition::GetInput (  )  [virtual]

Set/Get the input this transition is triggered by.

virtual void vtkKWStateMachineTransition::SetInput ( vtkKWStateMachineInput  )  [virtual]

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX

virtual vtkKWStateMachineState* vtkKWStateMachineTransition::GetDestinationState (  )  [virtual]

Set/Get the state this transition is leading to.

virtual void vtkKWStateMachineTransition::SetDestinationState ( vtkKWStateMachineState  )  [virtual]

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX

virtual int vtkKWStateMachineTransition::IsComplete (  )  [virtual]

Get if the transition is complete, i.e. it has an originating state (OriginState), a destination state (DestinationState), and an input (Input).

virtual void vtkKWStateMachineTransition::Start (  )  [virtual]

Start the transition. This method should be invoked when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. This can prove useful to push bew inputs that rely on the fact that the state machine is still at the OriginState. It will take care of calling the corresponding callbacks (StartCommand) and events (StartEvent). Subclasses that override this method should make sure they call their superclass's Start() method.

virtual void vtkKWStateMachineTransition::End (  )  [virtual]

End the transition. This command should be invoked when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. This can prove useful to push new inputs that rely on the fact that the state machine is now at the DestinationState. It will take care of calling the corresponding callbacks (EndCommand) and events (EndEvent). Subclasses that override this method should make sure they call their superclass's End() method.

virtual void vtkKWStateMachineTransition::SetStartCommand ( vtkObject object,
const char *  method 
) [virtual]

Specifies a command to associate with this transition. This command should be invoked when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. State machine (sub)classes should call the Start() method most of the time, which will take care of triggering this callback and firing the StartEvent as well. The 'object' argument is the object that will have the method called on it. The 'method' argument is the name of the method to be called and any arguments in string form. If the object is NULL, the method is still evaluated as a simple command.

virtual void vtkKWStateMachineTransition::InvokeStartCommand (  )  [virtual]

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX

virtual int vtkKWStateMachineTransition::HasStartCommand (  )  [virtual]

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX

virtual void vtkKWStateMachineTransition::SetEndCommand ( vtkObject object,
const char *  method 
) [virtual]

Specifies a command to associate with this transition. This command should be invoked when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. State machine (sub)classes should call the End() method most of the time, which will take care of triggering this callback and firing the EndEvent as well. The 'object' argument is the object that will have the method called on it. The 'method' argument is the name of the method to be called and any arguments in string form. If the object is NULL, the method is still evaluated as a simple command.

virtual void vtkKWStateMachineTransition::InvokeEndCommand (  )  [virtual]

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX

virtual int vtkKWStateMachineTransition::HasEndCommand (  )  [virtual]

Events. The StartEvent should be fired when the transition is "started" by the state machine, as the state machine is about to leave the OriginState but has not yet entered the DestinationState. The "EndEvent" should be fired when the transition is "ended" by the state machine, as the state machine has left the OriginState and already entered the DestinationState. In both case, State machine (sub)classes should call the corresponding Start() end End() methods most of the time, which will take care of triggering both the callbacks and firing the events. BTX


Member Data Documentation

Definition at line 151 of file vtkKWStateMachineTransition.h.

Definition at line 152 of file vtkKWStateMachineTransition.h.

Definition at line 153 of file vtkKWStateMachineTransition.h.

Definition at line 154 of file vtkKWStateMachineTransition.h.

Definition at line 156 of file vtkKWStateMachineTransition.h.

Definition at line 157 of file vtkKWStateMachineTransition.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Tue Apr 27 02:38:01 2010 for KWWidgets by  doxygen 1.6.1