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

#include "LocalSessionService.h"

Inheritance diagram for LocalSessionService:
ot::Serializable

Public Member Functions

 LocalSessionService ()
 
 LocalSessionService (const LocalSessionService &_other)
 
virtual ~LocalSessionService ()
 
LocalSessionServiceoperator= (const LocalSessionService &_other)
 
void setUrl (const std::string &_url)
 
const std::string & url (void) const
 
void setSessions (const std::list< Session * > &_sessions)
 
const std::list< Session * > & sessions (void) const
 
void setId (ot::serviceID_t _id)
 
ot::serviceID_t id (void) const
 
bool addSession (const Session &_session)
 
void removeSession (Session *_session)
 
size_t sessionCount (void) const
 
SessiongetSessionById (const std::string &_sessionId)
 
virtual void addToJsonObject (ot::JsonValue &_object, ot::JsonAllocator &_allocator) const override
 Add the object contents to the provided JSON object.
 
virtual void setFromJsonObject (const ot::ConstJsonObject &_object) override
 Will set the object contents from the provided JSON object.
 
void clear ()
 
- Public Member Functions inherited from ot::Serializable
 Serializable ()
 
virtual ~Serializable ()
 

Constructor & Destructor Documentation

◆ LocalSessionService() [1/2]

LocalSessionService::LocalSessionService ( )

◆ LocalSessionService() [2/2]

LocalSessionService::LocalSessionService ( const LocalSessionService & _other)

◆ ~LocalSessionService()

LocalSessionService::~LocalSessionService ( )
virtual

Member Function Documentation

◆ addSession()

bool LocalSessionService::addSession ( const Session & _session)

◆ addToJsonObject()

void LocalSessionService::addToJsonObject ( ot::JsonValue & _object,
ot::JsonAllocator & _allocator ) const
overridevirtual

Add the object contents to the provided JSON object.

Parameters
_objectJson object reference
_allocatorAllocator

Implements ot::Serializable.

◆ clear()

void LocalSessionService::clear ( void )

◆ getSessionById()

Session * LocalSessionService::getSessionById ( const std::string & _sessionId)

◆ id()

ot::serviceID_t LocalSessionService::id ( void ) const
inline

◆ operator=()

LocalSessionService & LocalSessionService::operator= ( const LocalSessionService & _other)

◆ removeSession()

void LocalSessionService::removeSession ( Session * _session)

◆ sessionCount()

size_t LocalSessionService::sessionCount ( void ) const

◆ sessions()

const std::list< Session * > & LocalSessionService::sessions ( void ) const
inline

◆ setFromJsonObject()

void LocalSessionService::setFromJsonObject ( const ot::ConstJsonObject & _object)
overridevirtual

Will set the object contents from the provided JSON object.

Parameters
_objectThe JSON object containing the information
Exceptions
Willthrow an exception if the provided object is not valid (members missing or invalid types)

Implements ot::Serializable.

◆ setId()

void LocalSessionService::setId ( ot::serviceID_t _id)
inline

◆ setSessions()

void LocalSessionService::setSessions ( const std::list< Session * > & _sessions)
inline

◆ setUrl()

void LocalSessionService::setUrl ( const std::string & _url)
inline

◆ url()

const std::string & LocalSessionService::url ( void ) const
inline

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