Inheritance diagram for sword::HttpClient:

Public Types | |
|
typedef std::map< std::string, std::string > | Arguments |
| enum | Code { Success, AuthRequired, FileNotFound, Error } |
| enum | PostMethod { Get, Post } |
Public Methods | |
| HttpClient (const URL &url, HttpSession &session) | |
| void | addHeader (const std::string &line) |
| Add an http header line to the request. | |
| Code | fetch () |
| Sends the request and fetch the document. | |
| Code | fetch (const Arguments &arguments, PostMethod method) |
| Sends the request and fetch the document. | |
| std::string | replyValue (const std::string &name) const |
| Obtain a reply value. | |
| word | size () const |
| Obtain the size of the document, or '0' if it could not be computed. | |
| word | read (void *buffer, word length) |
| Read data from the document (implements IStorage). | |
|
|
Add an http header line to the request.
The line must not include the end-of-line " |
|
||||||||||||
|
Sends the request and fetch the document.
|
|
|
Sends the request and fetch the document.
|
|
||||||||||||
|
Read data from the document (implements IStorage).
Reimplemented from sword::IStorage. |
|
|
Obtain a reply value. All reply value names are set to all lower case while fetching the page. So all access to this method must use only lower case names. If the value is not available, an empty string is returned. |
|
|
Obtain the size of the document, or '0' if it could not be computed. Some web pages are returned as a fixed-size blob (and their size were available in the request answer header, but some web pages are returned more as "streams" (chunked for instance), and their size cannot be predicted. |
1.3-rc2