X-Git-Url: https://git.sesse.net/?p=greproxy;a=blobdiff_plain;f=protocol.h;h=acbaa3b489f51d368a370e524d6a0ebc6ddc0bfb;hp=a6d33094af8c40f05222cf17325bbe459d961a1d;hb=HEAD;hpb=2b1c67c9a219ea85de7db4ada9364da3905e7b62 diff --git a/protocol.h b/protocol.h index a6d3309..acbaa3b 100644 --- a/protocol.h +++ b/protocol.h @@ -4,10 +4,15 @@ #include #include -class Protocol { +class Sender { +public: + virtual void send_packet(uint16_t proto, const std::string &data, uint32_t incoming_seq) = 0; +}; + +class Reader { public: - virtual void send_packet(uint16_t proto, const std::string &data) = 0; virtual int fd() const = 0; + virtual void read_packet(Sender* sender) = 0; }; #endif // !defined(_PROTOCOL_H)