CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Private Attributes
smproxy::Stopping Class Reference

#include <States.h>

Inheritance diagram for smproxy::Stopping:
smproxy::State< Stopping, AllOk > smproxy::StateName

Public Types

typedef boost::mpl::list
< boost::statechart::transition
< StoppingDone, Ready > > 
reactions
 

Public Member Functions

void activity ()
 
virtual void entryAction ()
 
virtual void exitAction ()
 
 Stopping (my_context c)
 
virtual ~Stopping ()
 
- Public Member Functions inherited from smproxy::State< Stopping, AllOk >
std::string stateName () const
 

Private Attributes

boost::scoped_ptr< boost::thread > stoppingThread_
 

Additional Inherited Members

- Protected Types inherited from smproxy::State< Stopping, AllOk >
typedef
boost::statechart::state
< Stopping, AllOk,
boost::mpl::list
<>, boost::statechart::has_no_history > 
boost_state
 
typedef State my_state
 
- Protected Member Functions inherited from smproxy::State< Stopping, AllOk >
void safeEntryAction ()
 
void safeExitAction ()
 
 State (const std::string stateName, typename boost_state::my_context &c)
 
virtual ~State ()
 
- Protected Attributes inherited from smproxy::State< Stopping, AllOk >
const std::string stateName_
 

Detailed Description

The Stopping state of the outer-state AllOk.

Definition at line 310 of file States.h.

Member Typedef Documentation

typedef boost::mpl::list< boost::statechart::transition<StoppingDone,Ready> > smproxy::Stopping::reactions

Definition at line 317 of file States.h.

Constructor & Destructor Documentation

smproxy::Stopping::Stopping ( my_context  c)
inline

Definition at line 319 of file States.h.

References smproxy::State< Stopping, AllOk >::safeEntryAction().

319  : my_state("Stopping", c)
320  { safeEntryAction(); }
virtual smproxy::Stopping::~Stopping ( )
inlinevirtual

Definition at line 321 of file States.h.

References smproxy::State< Stopping, AllOk >::safeExitAction().

Member Function Documentation

void smproxy::Stopping::activity ( )

Definition at line 261 of file StateMachine.cc.

Referenced by entryAction().

262  {
263  outermost_context_type& stateMachine = outermost_context();
264  stateMachine.disableConsumerRegistration();
265  boost::this_thread::interruption_point();
266  stateMachine.clearQueues();
267  boost::this_thread::interruption_point();
268  stateMachine.processEvent( StoppingDone() );
269  }
void smproxy::Stopping::entryAction ( )
virtual

Reimplemented from smproxy::State< Stopping, AllOk >.

Definition at line 253 of file StateMachine.cc.

References activity(), and stoppingThread_.

254  {
255  stoppingThread_.reset(
256  new boost::thread( boost::bind( &Stopping::activity, this) )
257  );
258  }
boost::scoped_ptr< boost::thread > stoppingThread_
Definition: States.h:329
void smproxy::Stopping::exitAction ( )
virtual

Reimplemented from smproxy::State< Stopping, AllOk >.

Definition at line 272 of file StateMachine.cc.

References stoppingThread_.

273  {
274  stoppingThread_->interrupt();
275  }
boost::scoped_ptr< boost::thread > stoppingThread_
Definition: States.h:329

Member Data Documentation

boost::scoped_ptr<boost::thread> smproxy::Stopping::stoppingThread_
private

Definition at line 329 of file States.h.

Referenced by entryAction(), and exitAction().