Class ServerSessionBase

Inheritance Relationships

Derived Type

Class Documentation

class ServerSessionBase

Subclassed by ecal_service::ServerSessionV1

Public Types

using ShutdownCallbackT = std::function<void(const std::shared_ptr<ServerSessionBase>&)>

Public Functions

ServerSessionBase(const ServerSessionBase&) = delete
ServerSessionBase(ServerSessionBase&&) = delete
ServerSessionBase &operator=(const ServerSessionBase&) = delete
ServerSessionBase &operator=(ServerSessionBase&&) = delete
virtual ~ServerSessionBase() = default
inline asio::ip::tcp::socket &socket()
virtual void start() = 0
virtual void stop() = 0
virtual ecal_service::State get_state() const = 0

Protected Functions

inline ServerSessionBase(const std::shared_ptr<asio::io_context> &io_context, const ServerServiceCallbackT &service_callback, const std::shared_ptr<asio::io_context::strand> &service_callback_strand, const ServerEventCallbackT &event_callback, const ShutdownCallbackT &shutdown_callback)

Protected Attributes

const std::shared_ptr<asio::io_context> io_context_
asio::ip::tcp::socket socket_
mutable std::mutex socket_mutex_
const ServerServiceCallbackT service_callback_
const std::shared_ptr<asio::io_context::strand> service_callback_strand_
const ServerEventCallbackT event_callback_
const ShutdownCallbackT shutdown_callback_