Kea 2.5.9
isc::asiolink::IOServiceMgr Class Reference

Class which handles events on IOService objects. More...

#include <io_service_mgr.h>

+ Inheritance diagram for isc::asiolink::IOServiceMgr:

Public Member Functions

void clearIOServices ()
 Clear the list of IOService objects.
 
size_t getIOServiceCount ()
 The count of IOService objects.
 
void pollIOServices ()
 Poll IOService objects.
 
void registerIOService (IOServicePtr io_service)
 Register IOService.
 
void unregisterIOService (IOServicePtr io_service)
 Unregister IOService.
 

Static Public Member Functions

static IOServiceMgrinstance ()
 Access the IOServiceMgr singleton instance.
 

Detailed Description

Class which handles events on IOService objects.

Usually hook libraries create a local IOService object which handles events related to the respective library. To be able to handle these events, the IOService objects need to be registered on the '[X]_srv_configured' or on 'load' hook points (before the MT settings are applied). This class is not thread safe, so all operations must be done on the main thread, while all other threads are either stopped or paused.

Definition at line 27 of file io_service_mgr.h.

Member Function Documentation

◆ clearIOServices()

◆ getIOServiceCount()

size_t isc::asiolink::IOServiceMgr::getIOServiceCount ( )
inline

The count of IOService objects.

Definition at line 60 of file io_service_mgr.h.

◆ instance()

◆ pollIOServices()

◆ registerIOService()

void isc::asiolink::IOServiceMgr::registerIOService ( IOServicePtr  io_service)

Register IOService.

Registering a null IOService does nothing. One IOService object can be registered only once, all consecutive calls using the same object will be silently ignored.

Parameters
io_serviceThe IOService to be registered.

Definition at line 20 of file io_service_mgr.cc.

Referenced by dhcp4_srv_configured(), and dhcp6_srv_configured().

◆ unregisterIOService()

void isc::asiolink::IOServiceMgr::unregisterIOService ( IOServicePtr  io_service)

Unregister IOService.

Unregistering an non registered IOService object will be silently ignored.

Parameters
io_serviceThe IOService to be unregistered.

Definition at line 31 of file io_service_mgr.cc.

Referenced by unload().


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