PluginProbe ʕ •ᴥ•ʔ
Independent Analytics – WordPress Analytics Plugin / 2.15.0
Independent Analytics – WordPress Analytics Plugin v2.15.0
2.15.0 2.14.10 trunk 1.1 1.10 1.10.1 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.17.1 1.17.2 1.17.3 1.17.4 1.18 1.18.1 1.19.0 1.19.1 1.2 1.20.0 1.21.0 1.22.0 1.22.1 1.23.0 1.23.1 1.24.0 1.24.1 1.25.0 1.25.1 1.26.0 1.27.0 1.28.0 1.28.1 1.28.2 1.28.3 1.29.0 1.3 1.30.0 1.30.1 1.4 1.5 1.6 1.7 1.8 1.9 2.0.0 2.0.1 2.1.4 2.1.5 2.1.6 2.10.0 2.10.1 2.10.2 2.10.3 2.10.4 2.11.0 2.11.1 2.11.10 2.11.2 2.11.3 2.11.4 2.11.5 2.11.6 2.11.7 2.11.8 2.11.9 2.12.0 2.12.1 2.12.2 2.13.1 2.13.2 2.13.5 2.13.6 2.14.0 2.14.1 2.14.2 2.14.4 2.14.6 2.14.7 2.14.8 2.14.9 2.2.0 2.2.1 2.3.1 2.3.2 2.4.2 2.4.3 2.5.0 2.5.1 2.6.0 2.6.1 2.6.2 2.6.3 2.6.4 2.7.0 2.7.1 2.7.2 2.7.3 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7 2.8.8 2.8.9 2.9.2 2.9.3 2.9.4 2.9.5 2.9.6 2.9.7
independent-analytics / vendor / psr / http-message / src / RequestInterface.php
independent-analytics / vendor / psr / http-message / src Last commit date
MessageInterface.php 2 years ago RequestInterface.php 2 years ago ResponseInterface.php 2 years ago ServerRequestInterface.php 2 years ago StreamInterface.php 2 years ago UploadedFileInterface.php 2 years ago UriInterface.php 2 years ago
RequestInterface.php
127 lines
1 <?php
2
3 declare (strict_types=1);
4 namespace IAWPSCOPED\Psr\Http\Message;
5
6 /**
7 * Representation of an outgoing, client-side request.
8 *
9 * Per the HTTP specification, this interface includes properties for
10 * each of the following:
11 *
12 * - Protocol version
13 * - HTTP method
14 * - URI
15 * - Headers
16 * - Message body
17 *
18 * During construction, implementations MUST attempt to set the Host header from
19 * a provided URI if no Host header is provided.
20 *
21 * Requests are considered immutable; all methods that might change state MUST
22 * be implemented such that they retain the internal state of the current
23 * message and return an instance that contains the changed state.
24 * @internal
25 */
26 interface RequestInterface extends MessageInterface
27 {
28 /**
29 * Retrieves the message's request target.
30 *
31 * Retrieves the message's request-target either as it will appear (for
32 * clients), as it appeared at request (for servers), or as it was
33 * specified for the instance (see withRequestTarget()).
34 *
35 * In most cases, this will be the origin-form of the composed URI,
36 * unless a value was provided to the concrete implementation (see
37 * withRequestTarget() below).
38 *
39 * If no URI is available, and no request-target has been specifically
40 * provided, this method MUST return the string "/".
41 *
42 * @return string
43 */
44 public function getRequestTarget();
45 /**
46 * Return an instance with the specific request-target.
47 *
48 * If the request needs a non-origin-form request-target — e.g., for
49 * specifying an absolute-form, authority-form, or asterisk-form —
50 * this method may be used to create an instance with the specified
51 * request-target, verbatim.
52 *
53 * This method MUST be implemented in such a way as to retain the
54 * immutability of the message, and MUST return an instance that has the
55 * changed request target.
56 *
57 * @link http://tools.ietf.org/html/rfc7230#section-5.3 (for the various
58 * request-target forms allowed in request messages)
59 * @param string $requestTarget
60 * @return static
61 */
62 public function withRequestTarget(string $requestTarget);
63 /**
64 * Retrieves the HTTP method of the request.
65 *
66 * @return string Returns the request method.
67 */
68 public function getMethod();
69 /**
70 * Return an instance with the provided HTTP method.
71 *
72 * While HTTP method names are typically all uppercase characters, HTTP
73 * method names are case-sensitive and thus implementations SHOULD NOT
74 * modify the given string.
75 *
76 * This method MUST be implemented in such a way as to retain the
77 * immutability of the message, and MUST return an instance that has the
78 * changed request method.
79 *
80 * @param string $method Case-sensitive method.
81 * @return static
82 * @throws \InvalidArgumentException for invalid HTTP methods.
83 */
84 public function withMethod(string $method);
85 /**
86 * Retrieves the URI instance.
87 *
88 * This method MUST return a UriInterface instance.
89 *
90 * @link http://tools.ietf.org/html/rfc3986#section-4.3
91 * @return UriInterface Returns a UriInterface instance
92 * representing the URI of the request.
93 */
94 public function getUri();
95 /**
96 * Returns an instance with the provided URI.
97 *
98 * This method MUST update the Host header of the returned request by
99 * default if the URI contains a host component. If the URI does not
100 * contain a host component, any pre-existing Host header MUST be carried
101 * over to the returned request.
102 *
103 * You can opt-in to preserving the original state of the Host header by
104 * setting `$preserveHost` to `true`. When `$preserveHost` is set to
105 * `true`, this method interacts with the Host header in the following ways:
106 *
107 * - If the Host header is missing or empty, and the new URI contains
108 * a host component, this method MUST update the Host header in the returned
109 * request.
110 * - If the Host header is missing or empty, and the new URI does not contain a
111 * host component, this method MUST NOT update the Host header in the returned
112 * request.
113 * - If a Host header is present and non-empty, this method MUST NOT update
114 * the Host header in the returned request.
115 *
116 * This method MUST be implemented in such a way as to retain the
117 * immutability of the message, and MUST return an instance that has the
118 * new UriInterface instance.
119 *
120 * @link http://tools.ietf.org/html/rfc3986#section-4.3
121 * @param UriInterface $uri New request URI to use.
122 * @param bool $preserveHost Preserve the original state of the Host header.
123 * @return static
124 */
125 public function withUri(UriInterface $uri, bool $preserveHost = \false);
126 }
127