30 void setUrl(
const std::string& _url) { m_url = _url; };
31 const std::string&
url(
void)
const {
return m_url; };
33 void setSessions(
const std::list<Session*>& _sessions) { m_sessions = _sessions; };
34 const std::list<Session*>&
sessions(
void)
const {
return m_sessions; };
62 std::list<Session*> m_sessions;
This file contains defines that may be used simplyfy class creation.
Definition LocalSessionService.h:18
virtual ~LocalSessionService()
Definition LocalSessionService.cpp:25
virtual void setFromJsonObject(const ot::ConstJsonObject &_object) override
Will set the object contents from the provided JSON object.
Definition LocalSessionService.cpp:75
const std::list< Session * > & sessions(void) const
Definition LocalSessionService.h:34
void removeSession(Session *_session)
Definition LocalSessionService.cpp:45
void setSessions(const std::list< Session * > &_sessions)
Definition LocalSessionService.h:33
const std::string & url(void) const
Definition LocalSessionService.h:31
void setId(ot::serviceID_t _id)
Definition LocalSessionService.h:36
size_t sessionCount(void) const
Definition LocalSessionService.cpp:53
bool addSession(const Session &_session)
Definition LocalSessionService.cpp:40
void setUrl(const std::string &_url)
Definition LocalSessionService.h:30
virtual void addToJsonObject(ot::JsonValue &_object, ot::JsonAllocator &_allocator) const override
Add the object contents to the provided JSON object.
Definition LocalSessionService.cpp:66
Session * getSessionById(const std::string &_sessionId)
Definition LocalSessionService.cpp:55
LocalSessionService()
Definition LocalSessionService.cpp:15
void clear()
Definition LocalSessionService.cpp:86
LocalSessionService & operator=(const LocalSessionService &_other)
Definition LocalSessionService.cpp:31
ot::serviceID_t id(void) const
Definition LocalSessionService.h:37
The Serializable class is the default interface of serializable objects.
Definition Serializable.h:17
unsigned short serviceID_t
ID type used to identify a service (16 bit unsigned integer).
Definition CoreTypes.h:14
rapidjson::Value JsonValue
Writable JSON value.
Definition JSON.h:27
rapidjson::GenericObject< true, rapidjson::GenericValue< rapidjson::UTF8<>, rapidjson::MemoryPoolAllocator< rapidjson::CrtAllocator > > > ConstJsonObject
Read only JSON Object.
Definition JSON.h:35
rapidjson::MemoryPoolAllocator< rapidjson::CrtAllocator > JsonAllocator
Allocator used for writing to JSON values.
Definition JSON.h:30