14 #ifndef CHUNKEDSTREAMBUF_H
15 #define CHUNKEDSTREAMBUF_H
29 class ChunkedStreamBuf :
public std::streambuf {
33 virtual ~ChunkedStreamBuf();
35 void open_read(BioStreamPtr *source, HTTPChannel *doc);
38 INLINE
bool is_closed()
const;
39 INLINE ISocketStream::ReadState get_read_state()
const;
42 virtual int underflow();
45 size_t read_chars(
char *start,
size_t length);
46 bool http_getline(std::string &str);
48 PT(BioStreamPtr) _source;
49 size_t _chunk_remaining;
51 bool _wanted_nonblocking;
52 std::string _working_getline;
53 ISocketStream::ReadState _read_state;
59 friend class IChunkedStream;
64 #endif // HAVE_OPENSSL