OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
ServiceManager Class Reference

#include "ServiceManager.h"

Public Member Functions

 ServiceManager ()
 
virtual ~ServiceManager ()
 
void addToJsonObject (ot::JsonValue &_object, ot::JsonAllocator &_allocator)
 Add the object contents to the provided JSON object.
 
void setServiceIP (const std::string &_ip)
 
const std::string & lastError (void) const
 
void setSiteID (const std::string &_siteID)
 
const std::string & siteID (void) const
 
bool requestStartService (const SessionInformation &_sessionInformation, const ServiceInformation &_serviceInformation)
 Will attempt to start a new service.
 
bool requestStartRelayService (const SessionInformation &_sessionInformation, std::string &_websocketUrl, std::string &_relayServiceURL)
 
void sessionClosed (const std::string &_sessionID)
 
void serviceDisconnected (const std::string &_sessionID, const ServiceInformation &_info, const std::string &_serviceURL)
 
void GetSessionInformation (ot::JsonArray &sessionInfo, ot::JsonAllocator &allocator)
 

Constructor & Destructor Documentation

◆ ServiceManager()

ServiceManager::ServiceManager ( )

◆ ~ServiceManager()

ServiceManager::~ServiceManager ( )
virtual

Member Function Documentation

◆ addToJsonObject()

void ServiceManager::addToJsonObject ( ot::JsonValue & _object,
ot::JsonAllocator & _allocator )

Add the object contents to the provided JSON object.

Parameters
_documentThe JSON document (used to get the allocator)
_objectThe JSON object to add the contents to

◆ GetSessionInformation()

void ServiceManager::GetSessionInformation ( ot::JsonArray & sessionInfo,
ot::JsonAllocator & allocator )

◆ lastError()

const std::string & ServiceManager::lastError ( void ) const
inline

◆ requestStartRelayService()

bool ServiceManager::requestStartRelayService ( const SessionInformation & _sessionInformation,
std::string & _websocketUrl,
std::string & _relayServiceURL )

◆ requestStartService()

bool ServiceManager::requestStartService ( const SessionInformation & _sessionInformation,
const ServiceInformation & _serviceInformation )

Will attempt to start a new service.

Parameters
_sessionInformationInformation about the session where the service should be connected to
_serviceInformationInformation about the service that should be started
_serviceURLThe URL where the service will be running will be written here

◆ serviceDisconnected()

void ServiceManager::serviceDisconnected ( const std::string & _sessionID,
const ServiceInformation & _info,
const std::string & _serviceURL )

◆ sessionClosed()

void ServiceManager::sessionClosed ( const std::string & _sessionID)

◆ setServiceIP()

void ServiceManager::setServiceIP ( const std::string & _ip)
inline

◆ setSiteID()

void ServiceManager::setSiteID ( const std::string & _siteID)
inline

◆ siteID()

const std::string & ServiceManager::siteID ( void ) const
inline

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