34 #ifndef PTLIB_SERVICEPROCESS_H 35 #define PTLIB_SERVICEPROCESS_H 149 #include "msos/ptlib/svcproc.h" 151 #include "unix/ptlib/svcproc.h" 156 #endif // PTLIB_SERVICEPROCESS_H WORD buildNumber
Definition: pprocess.h:715
Level
define the different error log levels
Definition: syslog.h:54
CodeStatus status
Definition: pprocess.h:714
WORD minorVersion
Definition: pprocess.h:713
virtual void OnContinue()
Resume after the service was paused.
This class represents an operating system process.
Definition: pprocess.h:227
BOOL PBoolean
Definition: object.h:102
WORD majorVersion
Definition: pprocess.h:712
PSystemLog::Level GetThresholdLevel() const
Get the current level for logging.
Definition: syslog.h:148
PBoolean debugMode
Flag to indicate service is run in simulation mode.
Definition: svcproc.h:145
A process type that runs as a "background" service.
Definition: svcproc.h:49
virtual PBoolean OnStart()=0
Called when the service is started.
virtual void OnControl()=0
The Control menu option was used in the SysTray menu.
virtual PBoolean OnPause()
Called by the system when the service is to be paused.
static PSystemLogTarget & GetTarget()
Get the current target/destination for system logging.
PSystemLog::Level GetLogLevel() const
Get the current level for logging.
Definition: svcproc.h:132
virtual int InternalMain(void *arg=NULL)
Main function for process, called from real main after initialisation.
virtual void OnStop()
Called by the system when the service is stopped.
void SetLogLevel(PSystemLog::Level level)
Set the level at which errors are logged.
Definition: svcproc.h:123
void SetThresholdLevel(PSystemLog::Level level)
Set the level at which errors are logged.
Definition: syslog.h:139
static PServiceProcess & Current()
Get the current service process object.
CodeStatus
Release status for the program.
Definition: pprocess.h:235
PServiceProcess(const char *manuf, const char *name, WORD majorVersion, WORD minorVersion, CodeStatus status, WORD buildNumber)
Create a new service process.