mdref.json config
[mdref/mdref-http] / http / Message.md
1 # class http\Message implements Countable, Serializable, Iterator
2
3 The message class builds the foundation for any request and response message.
4
5 See http\Client\Request and http\Client\Response, as well as http\Env\Request and http\Env\Response.
6
7 ## Constants:
8
9 * TYPE_NONE
10 No specific type of message.
11 * TYPE_REQUEST
12 A request message.
13 * TYPE_RESPONSE
14 A response message.
15
16 ## Properties:
17
18 * protected int $type = http\Message::TYPE_NONE
19 The message type. See http\Message::TYPE_* constants.
20 * protected http\Message\Body $body = NULL
21 The message's body.
22 * protected string $requestMethod = ""
23 The request method if the message is of type request.
24 * protected string $requestUrl = ""
25 The request url if the message is of type request.
26 * protected string $responseStatus = ""
27 The response status phrase if the message is of type response.
28 * protected int $responseCode = 0
29 The response code if the message is of type response.
30 * protected string $httpVersion = NULL
31 A custom HTTP protocol version.
32 * protected array $headers = NULL
33 Any message headers.
34 * protected http\Message $parentMessage
35 Any parent message.
36