nidas  v1.2-1520
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | List of all members
nidas::core::DSMService Class Referenceabstract

Base class for a service, as built from a <service> XML tag. More...

#include <DSMService.h>

Inheritance diagram for nidas::core::DSMService:
Inheritance graph
[legend]

Public Member Functions

 DSMService (const std::string &name)
 Constructor. More...
 
virtual ~DSMService ()
 
const std::string & getName () const
 
virtual void setDSMServer (DSMServer *val)
 
virtual DSMServergetDSMServer () const
 
virtual void connect (SampleInput *)=0 throw ()
 
virtual void addProcessor (SampleIOProcessor *proc)
 Add a processor to this RawSampleService. More...
 
virtual const std::list
< SampleIOProcessor * > & 
getProcessors () const
 
const std::list< SampleInput * > & getInputs () const
 
ProcessorIterator getProcessorIterator () const
 
virtual void schedule (bool optionalProcessing)=0 throw (nidas::util::Exception)
 schedule this service to run. More...
 
virtual int checkSubThreads () throw ()
 
virtual void cancel () throw ()
 
virtual void interrupt () throw ()
 
virtual int join () throw ()
 
void fromDOMElement (const xercesc::DOMElement *node) throw (nidas::util::InvalidParameterException)
 Initialize myself from a xercesc::DOMElement. More...
 
nidas::util::Thread::SchedPolicy getSchedPolicy () const
 
int getSchedPriority () const
 
virtual void printClock (std::ostream &) throw ()
 
virtual void printStatus (std::ostream &, float) throw ()
 
virtual xercesc::DOMElement * toDOMParent (xercesc::DOMElement *parent, bool complete) const throw (xercesc::DOMException)
 Create a DOMElement and append it to the parent. More...
 
virtual xercesc::DOMElement * toDOMElement (xercesc::DOMElement *node, bool complete) const throw (xercesc::DOMException)
 Add my content into a DOMElement. More...
 

Static Public Member Functions

static const std::string getClassName (const xercesc::DOMElement *node, const Project *) throw (nidas::util::InvalidParameterException)
 
static const XMLCh * getNamespaceURI ()
 

Protected Member Functions

void addSubThread (nidas::util::Thread *) throw ()
 

Protected Attributes

std::string _name
 
DSMServer_server
 
std::set< nidas::util::Thread * > _subThreads
 
nidas::util::Mutex _subThreadMutex
 
std::list< SampleInput * > _inputs
 
std::list< SampleIOProcessor * > _processors
 
std::list< IOChannel * > _ochans
 
nidas::util::Thread::SchedPolicy _threadPolicy
 
int _threadPriority
 

Private Member Functions

 DSMService (const DSMService &x)
 Copying not supported. More...
 
DSMServiceoperator= (const DSMService &x)
 Assignment not supported. More...
 

Detailed Description

Base class for a service, as built from a <service> XML tag.

Constructor & Destructor Documentation

DSMService::DSMService ( const std::string &  name)

Constructor.

DSMService::~DSMService ( )
virtual
nidas::core::DSMService::DSMService ( const DSMService x)
private

Copying not supported.

Member Function Documentation

virtual void nidas::core::DSMService::addProcessor ( SampleIOProcessor proc)
inlinevirtual

Add a processor to this RawSampleService.

This is done at configuration (XML) time.

References _processors.

void DSMService::addSubThread ( nidas::util::Thread thd)
throw (
)
protected
void DSMService::cancel ( )
throw (
)
virtual
int DSMService::checkSubThreads ( )
throw (
)
virtual
virtual void nidas::core::DSMService::connect ( SampleInput )
throw (
)
pure virtual
void DSMService::fromDOMElement ( const xercesc::DOMElement *  )
throw (nidas::util::InvalidParameterException
)
virtual
const string DSMService::getClassName ( const xercesc::DOMElement *  node,
const Project project 
)
throw (nidas::util::InvalidParameterException
)
static
virtual DSMServer* nidas::core::DSMService::getDSMServer ( ) const
inlinevirtual
const std::list<SampleInput*>& nidas::core::DSMService::getInputs ( ) const
inline

References _inputs.

const std::string& nidas::core::DSMService::getName ( ) const
inline
static const XMLCh* nidas::core::DOMable::getNamespaceURI ( )
inlinestaticinherited
ProcessorIterator DSMService::getProcessorIterator ( ) const
virtual const std::list<SampleIOProcessor*>& nidas::core::DSMService::getProcessors ( ) const
inlinevirtual
nidas::util::Thread::SchedPolicy nidas::core::DSMService::getSchedPolicy ( ) const
inline

References _threadPolicy.

int nidas::core::DSMService::getSchedPriority ( ) const
inline

References _threadPriority.

void DSMService::interrupt ( )
throw (
)
virtual
int DSMService::join ( )
throw (
)
virtual
DSMService& nidas::core::DSMService::operator= ( const DSMService x)
private

Assignment not supported.

virtual void nidas::core::DSMService::printClock ( std::ostream &  )
throw (
)
inlinevirtual
virtual void nidas::core::DSMService::printStatus ( std::ostream &  ,
float   
)
throw (
)
inlinevirtual
virtual void nidas::core::DSMService::schedule ( bool  optionalProcessing)
throw (nidas::util::Exception
)
pure virtual

schedule this service to run.

Implemented in nidas::dynld::RawSampleService, and nidas::dynld::XMLConfigService.

Referenced by nidas::core::DSMServer::scheduleServices().

void DSMService::setDSMServer ( DSMServer val)
virtual
xercesc::DOMElement * DOMable::toDOMElement ( xercesc::DOMElement *  node,
bool  complete 
) const
throw (xercesc::DOMException
)
virtualinherited
xercesc::DOMElement * DOMable::toDOMParent ( xercesc::DOMElement *  parent,
bool  complete 
) const
throw (xercesc::DOMException
)
virtualinherited

Member Data Documentation

std::list<SampleInput*> nidas::core::DSMService::_inputs
protected
std::string nidas::core::DSMService::_name
protected

Referenced by getName().

std::list<IOChannel*> nidas::core::DSMService::_ochans
protected

Referenced by ~DSMService().

std::list<SampleIOProcessor*> nidas::core::DSMService::_processors
protected
DSMServer* nidas::core::DSMService::_server
protected

Referenced by getDSMServer(), and setDSMServer().

nidas::util::Mutex nidas::core::DSMService::_subThreadMutex
protected
std::set<nidas::util::Thread*> nidas::core::DSMService::_subThreads
protected
nidas::util::Thread::SchedPolicy nidas::core::DSMService::_threadPolicy
protected

Referenced by getSchedPolicy().

int nidas::core::DSMService::_threadPriority
protected

Referenced by getSchedPriority().


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