18 #include <boost/asio.hpp> 20 #include "hazelcast/client/config/socket_options.h" 21 #include "hazelcast/client/address.h" 23 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) 25 #pragma warning(disable: 4251) //for dll export 30 namespace connection {
36 class ClientInvocation;
42 virtual ~
socket() =
default;
44 virtual void connect(
const std::shared_ptr<connection::Connection> connection) = 0;
47 async_write(
const std::shared_ptr<connection::Connection> connection,
48 const std::shared_ptr<spi::impl::ClientInvocation> invocation) = 0;
50 virtual void close() = 0;
52 virtual address get_address()
const = 0;
60 virtual boost::optional<address> local_socket_address()
const = 0;
62 virtual const address &get_remote_endpoint()
const = 0;
64 virtual boost::asio::io_context::strand &get_executor() noexcept = 0;
69 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64)
Represents an address of a client or member in the cluster.
Definition: address.h:36