omegalib
13.1
|
The base class for Services: a Service has code that is executed periodically (in the poll method) and can generate and queue events to be read by the user or other services. More...
#include <Service.h>
Public Types | |
enum | ServiceType { Pointer = EventBase::ServiceTypePointer, Mocap = EventBase::ServiceTypeMocap, Keyboard = EventBase::ServiceTypeKeyboard, Controller = EventBase::ServiceTypeController, Ui = EventBase::ServiceTypeUi, Generic = EventBase::ServiceTypeGeneric, Brain = EventBase::ServiceTypeBrain, Wand = EventBase::ServiceTypeWand, Speech = EventBase::ServiceTypeSpeech } |
This enumeration is kept for compatibility reason and may be removed in the future. More... | |
enum | ServicePollPriority { PollFirst, PollNormal, PollLast } |
Public Member Functions | |
Service () | |
int | getServiceId () |
virtual | ~Service () |
ServiceManager * | getManager () |
String | getName () |
bool | isInitialized () |
bool | isDebugEnabled () |
Returns true if debug mode is enabled for this service. More... | |
ServicePollPriority | getPollPriority () |
void | setPollPriority (ServicePollPriority value) |
virtual void | setup (Setting &settings) |
virtual void | initialize () |
virtual void | start () |
virtual void | poll () |
virtual void | stop () |
virtual void | dispose () |
void | lockEvents () |
void | unlockEvents () |
Event * | writeHead () |
Event * | readHead () |
Event * | readTail () |
Event * | getEvent (int index) |
void | doSetup (ServiceManager *mng, Setting &settings) |
void | doInitialize (ServiceManager *sm, int serviceId) |
Public Member Functions inherited from omicron::ReferenceType | |
ReferenceType () | |
virtual | ~ReferenceType () |
void | ref () |
void | unref () |
long | refCount () |
Friends | |
class | ServiceManager |
Additional Inherited Members | |
Static Public Member Functions inherited from omicron::ReferenceType | |
static void | printObjCounts () |
Static Protected Attributes inherited from omicron::ReferenceType | |
static List< ReferenceType * > | mysObjList |
The base class for Services: a Service has code that is executed periodically (in the poll method) and can generate and queue events to be read by the user or other services.
This enumeration is kept for compatibility reason and may be removed in the future.
To add new service types modify the relative enumeration in the EventBase class (connector/omicronConnectorClient.h)
Enumerator | |
---|---|
Pointer | |
Mocap | |
Keyboard | |
Controller | |
Ui | |
Generic | |
Brain | |
Wand | |
Speech |
|
inline |
|
inlinevirtual |
|
inlinevirtual |
Reimplemented in omega::MissionControlServer, omicron::MSKinectService, omicron::MSKinectService, omicron::OpenNIService, omicron::LegacyNetService, omicron::LegacyDirectInputService, omicron::AssetCacheService, omicron::WiimoteService, omicron::PQService, omicron::VRPNService, omicron::OptiTrackService, omicron::WandService, omicron::NaturalPointService, omicron::ThinkGearService, omicron::XInputService, omicron::DirectInputService, omicron::NetService, omicron::GestureService, omicron::PSMoveService, and omegaToolkit::WandPointerSwitcher.
void omicron::Service::doInitialize | ( | ServiceManager * | sm, |
int | serviceId | ||
) |
void omicron::Service::doSetup | ( | ServiceManager * | mng, |
Setting & | settings | ||
) |
Event* omicron::Service::getEvent | ( | int | index | ) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinevirtual |
Reimplemented in omega::MissionControlServer, omicron::TcpServer, omicron::MSKinectService, omicron::MSKinectService, omicron::OpenNIService, omicron::LegacyNetService, omicron::LegacyDirectInputService, omicron::AssetCacheService, omicron::WiimoteService, omicron::PQService, omicron::VRPNService, omicron::WandService, omicron::OptiTrackService, omicron::NaturalPointService, omicron::ThinkGearService, omicron::XInputService, omicron::DirectInputService, omicron::NetService, omicron::GestureService, omicron::PSMoveService, and omegaToolkit::WandPointerSwitcher.
|
inline |
Returns true if debug mode is enabled for this service.
|
inline |
void omicron::Service::lockEvents | ( | ) |
|
inlinevirtual |
Reimplemented in omicron::TcpServer, omicron::MSKinectService, omicron::MSKinectService, omicron::OpenNIService, omicron::LegacyNetService, omicron::LegacyDirectInputService, omicron::MocapGestureManager, omicron::WiimoteService, omicron::PQService, omicron::VRPNService, omicron::WandService, omicron::OptiTrackService, omicron::SagePointerService, omicron::ThinkGearService, omicron::XInputService, omicron::DirectInputService, omicron::HeartbeatService, omicron::NetService, omicron::GestureService, omicron::PSMoveService, and omegaToolkit::WandPointerSwitcher.
Event* omicron::Service::readHead | ( | ) |
Event* omicron::Service::readTail | ( | ) |
|
inline |
|
inlinevirtual |
Reimplemented in omicron::MSKinectService, omicron::MSKinectService, omicron::OpenNIService, omicron::LegacyNetService, omicron::LegacyDirectInputService, omicron::MocapGestureManager, omicron::PQService, omicron::WiimoteService, omicron::VRPNService, omicron::WandService, omicron::SagePointerService, omicron::ThinkGearService, omicron::XInputService, omicron::DirectInputService, omicron::HeartbeatService, omicron::NaturalPointService, omicron::NetService, omicron::GestureService, omicron::PSMoveService, and omegaToolkit::WandPointerSwitcher.
|
inlinevirtual |
Reimplemented in omicron::TcpServer, omicron::OpenNIService, omicron::OptiTrackService, and omicron::NaturalPointService.
|
inlinevirtual |
Reimplemented in omicron::TcpServer, omicron::OpenNIService, omicron::OptiTrackService, and omicron::NaturalPointService.
void omicron::Service::unlockEvents | ( | ) |
Event* omicron::Service::writeHead | ( | ) |
|
friend |