codaObject::InterruptibleObject Class Reference

Extends RunObject to add interrupt capability. More...

#include <InterruptibleObject.hxx>

Inheritance diagram for codaObject::InterruptibleObject:
codaObject::RunObject codaObject::SessionObject codaObject::CodaObject

List of all members.

Public Member Functions

 InterruptibleObject (const string &UDL, const string &name, const string &descr, InterruptService *intSvc=NULL, const string &codaClass="USER", const cMsgSubscriptionConfig *scfg=NULL) throw (CodaException)
 InterruptibleObject constructor, invokes RunObject constructor.
 ~InterruptibleObject (void) throw ()
 Destructor does nothing.
virtual bool interrupt (unsigned int flag) throw (CodaException)
 Implements interrupt, dispatches to user routine.

Protected Member Functions

virtual bool download (const string &s) throw (CodaException)
 Implements download transition, dispatches to user routine.
virtual bool prestart (const string &s) throw (CodaException)
 Implements prestart transition, dispatches to user routine.
virtual bool go (const string &s) throw (CodaException)
 Implements go transition, dispatches to user routine.
virtual bool pause (const string &s) throw (CodaException)
 Implements pause transition, dispatches to user routine.
virtual bool resume (const string &s) throw (CodaException)
 Implements resume transition, dispatches to user routine.
virtual bool end (const string &s) throw (CodaException)
 Implements end transition, dispatches to user routine.
virtual bool reset (const string &s) throw (CodaException)
 Delete interrupt, dispatches to user routine.
virtual bool userInterrupt (unsigned int flag) throw (CodaException)
 Dummy user interrupt method.

Protected Attributes

dllIntFuncPtr dllInterrupt
 Pointer to interrupt function in dll.
InterruptServiceintSvc
 Pointer to interrupt service.

Detailed Description

Extends RunObject to add interrupt capability.

Has an InterruptService.

Warning:
User routines should be pthread-cancelable in case abort/reset command is received.

Definition at line 41 of file InterruptibleObject.hxx.


Constructor & Destructor Documentation

InterruptibleObject::InterruptibleObject ( const string &  udl,
const string &  Name,
const string &  Descr,
InterruptService IntSvc = NULL,
const string &  cClass = "USER",
const cMsgSubscriptionConfig *  scfg = NULL 
) throw (CodaException)

InterruptibleObject constructor, invokes RunObject constructor.

Parameters:
udl Main cMsg connection udl
name Object name
descr Object description
intSvc Interrupt service used to supply interrupt
cClass Coda class of object
scfg cMsg subscription config

Definition at line 45 of file InterruptibleObject.cc.

InterruptibleObject::~InterruptibleObject ( void   )  throw ()

Destructor does nothing.

Definition at line 66 of file InterruptibleObject.cc.


Member Function Documentation

bool InterruptibleObject::download ( const string &  s  )  throw (CodaException) [protected, virtual]

Implements download transition, dispatches to user routine.

Parameters:
s String from run control
Returns:
true If transition succeeded

Reimplemented from codaObject::RunObject.

Definition at line 78 of file InterruptibleObject.cc.

References codaObject::RunObject::download().

bool InterruptibleObject::end ( const string &  s  )  throw (CodaException) [protected, virtual]

Implements end transition, dispatches to user routine.

Parameters:
s String from run control
Returns:
true If transition succeeded

Reimplemented from codaObject::RunObject.

Definition at line 269 of file InterruptibleObject.cc.

References DALOG_ERROR, and codaObject::RunObject::end().

bool InterruptibleObject::go ( const string &  s  )  throw (CodaException) [protected, virtual]

Implements go transition, dispatches to user routine.

Parameters:
s String from run control
Returns:
true If transition succeeded

Reimplemented from codaObject::RunObject.

Definition at line 129 of file InterruptibleObject.cc.

References DALOG_ERROR.

bool InterruptibleObject::interrupt ( unsigned int  flag  )  throw (CodaException) [virtual]

Implements interrupt, dispatches to user routine.

Parameters:
flag Interrupt flag
Returns:
true If transition succeeded

Definition at line 176 of file InterruptibleObject.cc.

Referenced by codaObject::vxTIInterruptService::dispatchInterrupt(), codaObject::vxSIS3610InterruptService::dispatchInterrupt(), codaObject::PollingService::dispatchInterrupt(), and codaObject::linuxTITrigPollingService::dispatchInterrupt().

bool InterruptibleObject::pause ( const string &  s  )  throw (CodaException) [protected, virtual]

Implements pause transition, dispatches to user routine.

Parameters:
s String from run control
Returns:
true If transition succeeded

Reimplemented from codaObject::RunObject.

Definition at line 201 of file InterruptibleObject.cc.

References DALOG_ERROR, and codaObject::RunObject::pause().

bool InterruptibleObject::prestart ( const string &  s  )  throw (CodaException) [protected, virtual]

Implements prestart transition, dispatches to user routine.

Parameters:
s String from run control
Returns:
true If transition succeeded

Reimplemented from codaObject::RunObject.

Definition at line 100 of file InterruptibleObject.cc.

References DALOG_ERROR, and codaObject::RunObject::prestart().

bool InterruptibleObject::reset ( const string &  s  )  throw (CodaException) [protected, virtual]

Delete interrupt, dispatches to user routine.

Parameters:
s String from run control
Returns:
true If abort succeeded

Reimplemented from codaObject::RunObject.

Definition at line 299 of file InterruptibleObject.cc.

References DALOG_ERROR, and codaObject::RunObject::reset().

bool InterruptibleObject::resume ( const string &  s  )  throw (CodaException) [protected, virtual]

Implements resume transition, dispatches to user routine.

Parameters:
s String from run control
Returns:
true If transition succeeded

Reimplemented from codaObject::RunObject.

Definition at line 230 of file InterruptibleObject.cc.

References DALOG_ERROR.

bool InterruptibleObject::userInterrupt ( unsigned int  flag  )  throw (CodaException) [protected, virtual]

Dummy user interrupt method.

Definition at line 324 of file InterruptibleObject.cc.


Member Data Documentation

Pointer to interrupt function in dll.

Definition at line 68 of file InterruptibleObject.hxx.

Pointer to interrupt service.

Definition at line 69 of file InterruptibleObject.hxx.


The documentation for this class was generated from the following files:

Generated on 4 Feb 2014 for CodaObject by  doxygen 1.6.1