Http.hpp
Go to the documentation of this file.
142 HttpAnswer(enum HTTPAnswerCode _code = enet::HTTPAnswerCode::c400_badRequest, const std::string& _help="");
330 //bool post(const std::string& _address, const std::string& _contentType, const std::string& _data);
The server will not accept the request, because the request entity is too large.
std::function< void(std::vector< uint8_t > &)> Observer
Define an Observer: function pointer.
Definition: Http.hpp:232
Definition: Http.hpp:137
The server is delivering only part of the resource due to a range header sent by the client...
void connectHeader(CLASS_TYPE *_class, void(CLASS_TYPE::*_func)(const enet::HttpAnswer &))
Connect an function member on the signal with the shared_ptr object.
Definition: Http.hpp:339
The request was a legal request, but the server is refusing to respond to it. For use when authentica...
The server can only generate a response that is not accepted by the client.
The server either does not recognize the request method, or it lacks the ability to fulfill the reque...
The request could not be completed because of a conflict in the request.
Used in the resumable requests proposal to resume aborted PUT or POST requests.
The requester has asked the server to switch protocols.
The "Content-Length" is not defined. The server will not accept the request without it...
The requested page could not be found but may be available again in the future.
The request has been successfully processed, but is not returning any content.
Definition: Http.hpp:188
Reserved for future use.
std::function< void(const enet::HttpRequest &)> ObserverRequest
Define an Observer: function pointer.
Definition: Http.hpp:268
The server will not accept the request, because the media type is not supported.
Definition: Http.hpp:320
The request has been accepted for processing, but the processing has not been completed.
Used in the resumable requests proposal to resume aborted PUT or POST requests.
The request cannot be fulfilled due to bad syntax.
The request has been successfully processed, but is not returning any content, and requires that the ...
The requested page has moved to a new URL.
The server will not accept the request, because the URL is too long. Occurs when you convert a POST r...
int32_t write(const std::vector< T > &_data)
Write a chunk of data on the socket.
Definition: Http.hpp:308
The client needs to authenticate to gain network access.
The requested page is no longer available.
The server does not support the HTTP protocol version used in the request.
The request is OK (this is the standard response for successful HTTP requests)
A link list. The user can select a link and go to that location. Maximum five addresses.
A generic error message, given when no more specific message is suitable.
The server is currently unavailable (overloaded or down)
The request has been successfully processed, but is returning information that may be from another so...
Indicates the requested page has not been modified since last requested.
void connectRaw(CLASS_TYPE *_class, void(CLASS_TYPE::*_func)(enet::Tcp &))
Connect an function member on the signal with the shared_ptr object.
Definition: Http.hpp:259
The server has received the request headers, and the client should proceed to send the request body...
The requested page has moved temporarily to a new URL.
enum status getConnectionStatus() const
Get the current Status of the connection.
Definition: Tcp.hpp:62
A request was made of a page using a request method not supported by that page.
std::function< void(const enet::HttpAnswer &)> ObserverAnswer
Define an Observer: function pointer.
Definition: Http.hpp:272
int32_t write(const std::string &_data, bool _writeBackSlashZero=true)
Write a chunk of data on the socket.
Definition: Http.hpp:291
The precondition given in the request evaluated to false by the server.
The server was acting as a gateway or proxy and received an invalid response from the upstream server...
The server timed out waiting for the request.
Definition: Http.hpp:114
The client has asked for a portion of the file, but the server cannot supply that portion...
void connect(CLASS_TYPE *_class, void(CLASS_TYPE::*_func)(std::vector< uint8_t > &))
Connect an function member on the signal with the shared_ptr object.
Definition: Http.hpp:241
Definition: Tcp.hpp:16
The server cannot meet the requirements of the Expect request-header field.
The request was a legal request, but the server is refusing to respond to it.
Definition: Http.hpp:166
The requested page has moved temporarily to a new URL.
The client must first authenticate itself with the proxy.
No longer used.
The server was acting as a gateway or proxy and did not receive a timely response from the upstream s...
std::function< void(enet::Tcp &)> ObserverRaw
Define an Observer: function pointer.
Definition: Http.hpp:250
void connectHeader(CLASS_TYPE *_class, void(CLASS_TYPE::*_func)(const enet::HttpRequest &))
Connect an function member on the signal with the shared_ptr object.
Definition: Http.hpp:364
The requested page can be found under a different URL.
Definition: Http.hpp:349
The request has been fulfilled, and a new resource is created.