The HttpConn class provides a simple means for retrieving data through thr HTTP protocol.
Publicly inherits Connection.
HttpConn | ( const Url& url ); | |
virtual bool | open | ( ); |
virtual void | readable | ( ); |
virtual void | writable | ( ); |
void | procHeader | ( ); |
virtual void | data | ( const char* bytes, int length ); |
virtual void | endOfData | ( ); |
virtual void | startOfData | ( QString mediaType, QString mediaSubtype, int totalSize ); |
virtual void | status | ( QString msg ); |
virtual void | urlChanged | ( const Url& url ); |
QString | _header; |
QString | _location; |
QString | _mediaSubtype; |
QString | _mediaType; |
int | _reqStatus; |
QString | _reqStatusText; |
Create a new HttpConn.
Open an HTTP connection to a remote host. Look up the host, create a create a socket, send the request, and switch to non-blocking mode.
The connection has data to be read. Read it and emit it.
Process an HTTP header. We are interested in headers that specify the Internet media type, the data size, or the new location of the data.
Emit data as it is received.
Emit notification that the connection has been torn down.
Emit the Internet media type and size of the data stream.
Emit message about connection status and data transfered.
This signal is emitted when the URL being retrieved changes because of an HTTP redirect.