19 #ifndef INCLUDE_RCF_HTTPCONNECTFILTER_HPP
20 #define INCLUDE_RCF_HTTPCONNECTFILTER_HPP
22 #include <boost/shared_ptr.hpp>
24 #include <RCF/Filter.hpp>
25 #include <RCF/ByteBuffer.hpp>
29 class HttpConnectFilter :
public Filter
34 HttpConnectFilter(
const std::string serverAddr,
int serverPort);
39 const ByteBuffer &byteBuffer,
40 std::size_t bytesRequested);
42 void write(
const std::vector<ByteBuffer> &byteBuffers);
44 void onReadCompleted(
const ByteBuffer &byteBuffer);
46 void onWriteCompleted(std::size_t bytesTransferred);
48 int getFilterId()
const;
52 std::string mServerAddr;
57 std::vector<ByteBuffer> mOrigWriteBuffers;
59 std::string mHttpConnectRequest;
60 std::string mHttpConnectResponse;
62 std::size_t mWritePos;
65 std::vector<char> mReadVector;
70 #endif // ! INCLUDE_RCF_HTTPCONNECTFILTER_HPP