#pragma once #include "../common/seq_packet.h" class client { public: client(boost::asio::io_context & io_context, const std::string & unix_file, std::function&)> func_cb = nullptr); ~client(); void write(const std::vector & data); void do_close(); private: client(const client&) = delete; const client& operator=(const client&) = delete; seq_packet::seqpacket_protocol::socket socket_; std::array data_; std::function&)> callback_func; void handle_connect(const boost::system::error_code & error); void handle_read(const boost::system::error_code & error, size_t bytes_transferred); void start(); };