Open Lighting Architecture
0.9.1
|
The base class for a thread which handles all the SLP stuff.
Classes | |
struct | DiscoveryState |
struct | URLRegistrationState |
Public Types | |
typedef ola::BaseCallback1 < void, bool > | RegistrationCallback |
typedef ola::Callback2< void, bool, const ola::slp::URLEntries & > | DiscoveryCallback |
typedef ola::SingleUseCallback2< void, bool, const SLPThreadServerInfo & > | ServerInfoCallback |
Public Member Functions | |
BaseSLPThread (ola::thread::ExecutorInterface *executor, unsigned int discovery_interval=DEFAULT_DISCOVERY_INTERVAL_SECONDS) | |
bool | SetNewControllerCallback (DiscoveryCallback *callback) |
bool | SetNewDeviceCallback (DiscoveryCallback *callback) |
void | RegisterDevice (RegistrationCallback *callback, const IPV4Address &address, const UID &uid, uint16_t lifetime) |
void | RegisterController (RegistrationCallback *callback, const IPV4Address &address, uint16_t lifetime) |
void | DeRegisterDevice (RegistrationCallback *callback, const IPV4Address &address, const UID &uid) |
void | DeRegisterController (RegistrationCallback *callback, const IPV4Address &address) |
void | ServerInfo (ServerInfoCallback *callback) |
void | RunDeviceDiscoveryNow () |
virtual bool | Init () |
bool | Start () |
bool | Join (void *ptr=NULL) |
virtual void | Cleanup ()=0 |
Public Member Functions inherited from ola::thread::Thread | |
virtual bool | FastStart () |
bool | IsRunning () |
ThreadId | Id () const |
void * | _InternalRun () |
Static Public Attributes | |
static const unsigned int | DEFAULT_DISCOVERY_INTERVAL_SECONDS |
Protected Types | |
typedef ola::SingleUseCallback2< void, bool, const ola::slp::URLEntries & > | InternalDiscoveryCallback |
Protected Member Functions | |
void * | Run () |
void | RunCallbackInExecutor (RegistrationCallback *callback, bool ok) |
virtual void | RunDiscovery (InternalDiscoveryCallback *callback, const string &service)=0 |
virtual void | RegisterSLPService (RegistrationCallback *callback, const string &url, uint16_t lifetime)=0 |
virtual void | DeRegisterSLPService (RegistrationCallback *callback, const string &url)=0 |
virtual void | SLPServerInfo (ServerInfoCallback *callback)=0 |
virtual void | ThreadStopping () |
virtual uint16_t | MinRefreshTime () |
void | ReRegisterAllServices () |
Protected Attributes | |
ola::io::SelectServer | m_ss |
ola::thread::ExecutorInterface * | m_executor |
Static Protected Attributes | |
static const char | RDNMET_SCOPE [] |
Additional Inherited Members | |
Static Public Member Functions inherited from ola::thread::Thread | |
static ThreadId | Self () |