#include <IPeerDiscoveryService.hpp>
|
virtual bool | start (std::shared_ptr< config::IConfigurationProvider > config, IPeerDiscoveryCoreInterface *const core, std::shared_ptr< zmf::data::ModuleHandle > selfHandle, uint32_t multicastFrequency, uint16_t udpPort, bool peerDiscoveryWait, bool disableEqualModuleInterconnect)=0 |
|
virtual void | stop ()=0 |
|
virtual void | sendStateMulticast ()=0 |
|
virtual const std::shared_ptr
< zmf::discovery::PeerRegistry > & | getPeerRegistry ()=0 |
|
virtual void | updateSelfState (zmf::data::ModuleState state)=0 |
|
virtual void | updateSelfAdditionalState (std::vector< uint8_t > additionalState)=0 |
|
Interface to access the PeerDiscoveryService - Service class to recognize other modules and there states in the network. PeerStates can be accessed via PeerRegistry (getPeerRegistry)
- Author
- Jonas Grunert
- Date
- created on 7/7/15.
virtual const std::shared_ptr<zmf::discovery::PeerRegistry>& zmf::discovery::IPeerDiscoveryService::getPeerRegistry |
( |
| ) |
|
|
pure virtual |
virtual void zmf::discovery::IPeerDiscoveryService::sendStateMulticast |
( |
| ) |
|
|
pure virtual |
virtual bool zmf::discovery::IPeerDiscoveryService::start |
( |
std::shared_ptr< config::IConfigurationProvider > |
config, |
|
|
IPeerDiscoveryCoreInterface *const |
core, |
|
|
std::shared_ptr< zmf::data::ModuleHandle > |
selfHandle, |
|
|
uint32_t |
multicastFrequency, |
|
|
uint16_t |
udpPort, |
|
|
bool |
peerDiscoveryWait, |
|
|
bool |
disableEqualModuleInterconnect |
|
) |
| |
|
pure virtual |
Starts the peer discovery service: State broadcasting, peer discovery and module registry.
- Parameters
-
core | Reference to the ZMF core |
selfHandle | Module handle for the module of this instance. Contains information about module and its state |
broadcastFrequency | Frequency to send out state broadcasts (in milliseconds between broadcasts) |
udpPort | UDP port for state broadcast communication |
trackModuleStates | Flag to enable/disable tracking of module states. If disabled only module leave and join will be tracked |
- Returns
- Returns true if start successful, false otherwise
Implemented in zmf::discovery::PeerDiscoveryService.
virtual void zmf::discovery::IPeerDiscoveryService::stop |
( |
| ) |
|
|
pure virtual |
virtual void zmf::discovery::IPeerDiscoveryService::updateSelfAdditionalState |
( |
std::vector< uint8_t > |
additionalState | ) |
|
|
pure virtual |
virtual void zmf::discovery::IPeerDiscoveryService::updateSelfState |
( |
zmf::data::ModuleState |
state | ) |
|
|
pure virtual |
The documentation for this class was generated from the following file: