In file /home/eternity/Source/Eso/Scheduler/H/scheduler.h:

class Scheduler : public SixOffspring, public Runable, public Shutdownable

Schedules time's operation

Inheritance:

Scheduler < SixOffspring

Scheduler < Runable < Debugable

Scheduler < Shutdownable


Public


void* Run (void*)
Starts in stand-alone thread when is Eso starting
virtual void Shutdown ()
Sets state shutdown to true
Err SetTimeOut ( char *command, GMessage *info, RelTime time )
Sets timeout to relative time from current time
Err SetTimeOut ( char *command, GMessage *info, ESTime time )
Sets timeout to absolute time
bool IsSetTimeOut ( char *command )
Returns true if is timeout set
ESTime* GetTime ()
Return current time if is time ok or NULL if is time wrong

Protected


TimeSortedTable* tbl
sorted table for storing timeouts
pthread_mutex_t mutexTbl
mutex to work with sorted table tbl
bool TimeOk
state if time is ok or wrong
Table* tblTimeOk
persistent storing of state
pthread_mutex_t mutex
mutex to work with table tblTimeOk
bool shutdown
state if thread would shutdown

Err SetTimeOk (bool state)
Sets state TimeOk
bool GetTimeOk ()
Gets state TimeOk
void ProcessTimeOut ()
Searchs table tbl if is any expired timeout.
Err CommonSetTimeOut (char *command, GMessage *info, ESTime *pTime)
Common method for setting timeout.

Inherited from SixOffspring:

Public Methods

SixOffspring::SixOffspring(Six * aSix)

Public

methods

SixOffspring(Six *six)
Constructor.

Protected

attributes

Six* six
Pointer to Six.

Inherited from Runable:

Public Methods

void Runable::MaskAllSignals()
Runable::Runable(LogFile * logFile)

Inherited from Debugable:

Public Methods

string* Debugable::CreateString(char *firstStr, int firstInt, int secondInt)
Debugable::Debugable(LogFile * debugLogFile)
int Debugable::SetDebugOptions(int newLogOptions)
void Debugable::SetLogFile(LogFile *aLogFile)
void Debugable::WriteString(LogLevel debugLevel, char * format, ...)
Debugable::~Debugable()

Inherited from Shutdownable:

Public Methods

Shutdownable::Shutdownable(Killer * killer)

Documentation

Schedules time's operation. This is implemented by sending messages (timeouts), when would start some operation. Scheduler runs in stand-alone thread and provides setting timeouts and getting of current time.

Timeout has three items:

- command - name of timeouts
- info - some additional information
- time of expiration

TimeSortedTable* tbl
sorted table for storing timeouts

pthread_mutex_t mutexTbl
mutex to work with sorted table tbl

bool TimeOk
state if time is ok or wrong

Table* tblTimeOk
persistent storing of state

pthread_mutex_t mutex
mutex to work with table tblTimeOk

bool shutdown
state if thread would shutdown

Err SetTimeOk(bool state)
Sets state TimeOk

bool GetTimeOk()
Gets state TimeOk

void ProcessTimeOut()
Searchs table tbl if is any expired timeout.

Err CommonSetTimeOut(char *command, GMessage *info, ESTime *pTime)
Common method for setting timeout.

void* Run(void*)
Starts in stand-alone thread when is Eso starting

virtual void Shutdown()
Sets state shutdown to true

Err SetTimeOut( char *command, GMessage *info, RelTime time )
Sets timeout to relative time from current time

Err SetTimeOut( char *command, GMessage *info, ESTime time )
Sets timeout to absolute time

bool IsSetTimeOut( char *command )
Returns true if is timeout set

ESTime* GetTime()
Return current time if is time ok or NULL if is time wrong


This class has no child classes.
Author:
Jirka
See Also:
Eso

alphabetic index hierarchy of classes


generated by doc++