5#ifndef PT_HTTP_CHANNEL_H
6#define PT_HTTP_CHANNEL_H
8#include <Pt/Http/Api.h>
9#include <Pt/NonCopyable.h>
64 {
return _stream != 0; }
114 void onDetachStream(Stream&
stream);
bool isOpen() const
Returns true when a stream is bound.
Definition Channel.h:63
Channel(Stream &stream)
Creates a channel bound to stream.
Stream * stream() const
Returns the bound stream, or null.
Definition Channel.h:97
void close()
Releases the bound stream.
~Channel()
Releases the bound stream.
void open(Stream &stream)
Binds stream.
virtual void onClose()
Cleans up before the stream pointer is dropped.
Channel()
Creates a channel with no stream.
One HTTP stream on a connection.
Definition Stream.h:92
NonCopyable()
Default constructor.
Definition NonCopyable.h:63
HTTP clients and servers.
Core module.
Definition Allocator.h:33