Home

QtStateFinishedTransition Class Reference
[QtCore module]

The QtStateFinishedTransition class provides a transition that triggers when a state is finished. More...

 #include <QtStateFinishedTransition>

Inherits QtTransition.

Properties

Public Functions

Additional Inherited Members


Detailed Description

The QtStateFinishedTransition class provides a transition that triggers when a state is finished.

A state is finished when one of its final child states (a QtFinalState) is entered; this will cause a QtStateFinishedEvent to be generated. The QtStateFinishedTransition class provides a way of associating a transition with such an event. QtStateFinishedTransition is part of The State Machine Framework.

 QtStateMachine machine;
 QtState *s1 = new QtState(machine.rootState());
 QtState *s11 = new QtState(s1);
 QtFinalState *s12 = new QtFinalState(s1);
 s11->addTransition(s12);

 QtState *s2 = new QtState(machine.rootState());
 QtStateFinishedTransition *finishedTransition = new QtStateFinishedTransition(s1);
 finishedTransition->setTargetState(s2);
 s1->addTransition(finishedTransition);

See also QtState::addFinishedTransition() and QtStateFinishedEvent.


Property Documentation

state : QtState *

This property holds the state whose QtStateFinishedEvent this transition is associated with.

Access functions:


Member Function Documentation

QtStateFinishedTransition::QtStateFinishedTransition ( QtState * sourceState = 0 )

Constructs a new QtStateFinishedTransition object that has the given sourceState.

QtStateFinishedTransition::QtStateFinishedTransition ( QtState * state, const QList<QtAbstractState *> & targets, QtState * sourceState = 0 )

Constructs a new QtStateFinishedTransition object associated with the given state, and that has the given targets and sourceState.

QtStateFinishedTransition::~QtStateFinishedTransition ()

Destroys this QtStateFinishedTransition.


Copyright © 2009 Nokia Trademarks
Qt Solutions