TwiceAsNice  2019-02-18
Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Friends | List of all members
Basda::ServiceWorker::WorkerThread Class Reference

A thread associated with a private state machine and a private monitor variable. More...

#include <ServiceWorker.h>

Inheritance diagram for Basda::ServiceWorker::WorkerThread:
Inheritance graph
Collaboration diagram for Basda::ServiceWorker::WorkerThread:
Collaboration graph

Public Member Functions

 WorkerThread (ServiceWorker *_svc)
 
ServiceStateMachinestateMachine ()
 
Nice::Monitormonitor ()
 
void wait ()
 
bool timedWait (const Nice::Time &_timeout)
 
 WorkerThread (ServiceWorker *_svc)
 
ServiceStateMachinestateMachine ()
 
Nice::Monitormonitor ()
 
void wait ()
 
bool timedWait (const Nice::Time &_timeout)
 
- Public Member Functions inherited from Nice::Thread
 Thread ()
 
virtual ~Thread ()
 
IceUtil::ThreadControl start (size_t _stackSize=0, int prio=-1, int schedpolicy=-1, cpu_set_t *mask=0)
 
virtual void terminate ()
 
virtual bool terminated ()
 
virtual void cancel ()
 cancels a thread - this will throw an unknown exception More...
 
virtual void sleep (const Nice::Time &_t)
 
virtual void yield ()
 
virtual void wakeupAt (const Nice::Time &_t)
 
 Thread ()
 
virtual ~Thread ()
 
IceUtil::ThreadControl start (size_t _stackSize=0, int prio=-1, int schedpolicy=-1, cpu_set_t *mask=0)
 
virtual void terminate ()
 
virtual bool terminated ()
 
virtual void cancel ()
 cancels a thread - this will throw an unknown exception More...
 
virtual void sleep (const Nice::Time &_t)
 
virtual void yield ()
 
virtual void wakeupAt (const Nice::Time &_t)
 

Protected Member Functions

virtual void run ()
 the main ICE servicing loop. Executes a preinit() step and enters a loop that is terminated when the next state becomes SHUTDOWN. More...
 
virtual void run ()
 

Protected Attributes

ServiceStateMachine m_stateMachine
 
Nice::Monitor m_monitor
 
- Protected Attributes inherited from Nice::Thread
Nice::Atomic< boolm_terminated
 

Private Member Functions

 WorkerThread ()
 
 WorkerThread ()
 

Private Attributes

ServiceWorkerm_svc
 

Friends

class BasdardServiceWorker
 

Additional Inherited Members

- Protected Types inherited from Nice::Thread
enum  STATE {
  VALID, TERMINATED, CANCELED, VALID,
  TERMINATED, CANCELED
}
 
enum  STATE {
  VALID, TERMINATED, CANCELED, VALID,
  TERMINATED, CANCELED
}
 

Detailed Description

A thread associated with a private state machine and a private monitor variable.


Constructor & Destructor Documentation

◆ WorkerThread() [1/4]

Basda::ServiceWorker::WorkerThread::WorkerThread ( )
inlineprivate

◆ WorkerThread() [2/4]

Basda::ServiceWorker::WorkerThread::WorkerThread ( ServiceWorker _svc)
inline

◆ WorkerThread() [3/4]

Basda::ServiceWorker::WorkerThread::WorkerThread ( )
inlineprivate

◆ WorkerThread() [4/4]

Basda::ServiceWorker::WorkerThread::WorkerThread ( ServiceWorker _svc)
inline

Member Function Documentation

◆ monitor() [1/2]

Nice::Monitor& Basda::ServiceWorker::WorkerThread::monitor ( )
inline

◆ monitor() [2/2]

Nice::Monitor& Basda::ServiceWorker::WorkerThread::monitor ( )
inline

◆ run() [1/2]

void Basda::ServiceWorker::WorkerThread::run ( )
protectedvirtual

the main ICE servicing loop. Executes a preinit() step and enters a loop that is terminated when the next state becomes SHUTDOWN.


◆ run() [2/2]

virtual void Basda::ServiceWorker::WorkerThread::run ( )
protectedvirtual

◆ stateMachine() [1/2]

ServiceStateMachine& Basda::ServiceWorker::WorkerThread::stateMachine ( )
inline

◆ stateMachine() [2/2]

ServiceStateMachine& Basda::ServiceWorker::WorkerThread::stateMachine ( )
inline

◆ timedWait() [1/2]

bool Basda::ServiceWorker::WorkerThread::timedWait ( const Nice::Time _timeout)
inline

◆ timedWait() [2/2]

bool Basda::ServiceWorker::WorkerThread::timedWait ( const Nice::Time _timeout)
inline

◆ wait() [1/2]

void Basda::ServiceWorker::WorkerThread::wait ( )
inlinevirtual

Reimplemented from Nice::Thread.

◆ wait() [2/2]

void Basda::ServiceWorker::WorkerThread::wait ( )
inlinevirtual

Reimplemented from Nice::Thread.

Friends And Related Function Documentation

◆ BasdardServiceWorker

Member Data Documentation

◆ m_monitor

Nice::Monitor Basda::ServiceWorker::WorkerThread::m_monitor
protected

◆ m_stateMachine

ServiceStateMachine Basda::ServiceWorker::WorkerThread::m_stateMachine
protected

◆ m_svc

ServiceWorker * Basda::ServiceWorker::WorkerThread::m_svc
private

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