X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/70f8adff2c970496bdc45717cad49ddec0405ae7..20072b367cf034ab9124560e4a06d8e32a388d93:/stglibs/sgcp.lib/include/stg/sgcp_transport.h?ds=sidebyside diff --git a/stglibs/sgcp.lib/include/stg/sgcp_transport.h b/stglibs/sgcp.lib/include/stg/sgcp_transport.h index 88a7d0c4..6e24756a 100644 --- a/stglibs/sgcp.lib/include/stg/sgcp_transport.h +++ b/stglibs/sgcp.lib/include/stg/sgcp_transport.h @@ -43,13 +43,11 @@ class TransportProto }; static TransportProto* create(TransportType transport, const std::string& key); - static TransportProto* create(TransportType transport); virtual ~TransportProto() {} - virtual void connect(const std::string& address, uint16_t port) = 0; - virtual ssize_t write(const void* buf, size_t size) = 0; - virtual ssize_t read(void* buf, size_t size) = 0; + virtual ConnectionPtr connect(const std::string& address, uint16_t port) = 0; + virtual void bind(const std::string& address, uint16_t port, Proto::AcceptHandler handler) = 0; }; } // namespace SGCP