Poco::Netconf

class SessionManager

Library: Netconf
Package: Service
Header: Poco/Netconf/SessionManager.h

Description

Singleton class storing for clients session ids

Member Summary

Member Functions: createSessionId, instance, registerSession, unregisterSession

Constructors

Destructor

~SessionManager protected

~SessionManager();

Destroys the SessionManager.

Member Functions

createSessionId

Poco::UInt32 createSessionId();

Generates a new session id.

instance static

static SessionManager & instance();

Returns the SessionManager instance.

registerSession

const std::string & registerSession(
    const Poco::Net::SocketAddress & adr,
    Poco::UInt32 sessionId
);

Registers for a client the sessionId. Returns the clientId.

unregisterSession

void unregisterSession(
    const std::string & clientId
);

Removes session information for the given client