PluginProbe
WPFunnels – Funnel Builder for WooCommerce with Checkout & One Click Upsell / 2.8.16
WPFunnels – Funnel Builder for WooCommerce with Checkout & One Click Upsell v2.8.16
3.13.3 3.13.2 3.13.1 3.13.0 3.12.13 3.12.12 3.12.11 3.12.10 3.12.9 3.12.8 3.12.7 3.12.6 3.12.5 3.12.4 3.12.3 3.12.1 3.12.2 3.12.0 3.11.1 3.11.0 3.10.9 3.10.8 3.10.7 3.10.6 2.8.16 All 261 releases
wpfunnels / vendor / symfony / browser-kit / Request.php

Request.php in WPFunnels – Funnel Builder for WooCommerce with Checkout & One Click Upsell 2.8.16, at vendor/symfony/browser-kit/Request.php

122 lines 2.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 /*
4 * This file is part of the Symfony package.
5 *
6 * (c) Fabien Potencier <[email protected]>
7 *
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
10 */
11
12 namespace Symfony\Component\BrowserKit;
13
14 /**
15 * @author Fabien Potencier <[email protected]>
16 */
17 class Request
18 {
19 protected $uri;
20 protected $method;
21 protected $parameters;
22 protected $files;
23 protected $cookies;
24 protected $server;
25 protected $content;
26
27 /**
28 * @param string $uri The request URI
29 * @param string $method The HTTP method request
30 * @param array $parameters The request parameters
31 * @param array $files An array of uploaded files
32 * @param array $cookies An array of cookies
33 * @param array $server An array of server parameters
34 * @param string $content The raw body data
35 */
36 public function __construct(string $uri, string $method, array $parameters = [], array $files = [], array $cookies = [], array $server = [], string $content = null)
37 {
38 $this->uri = $uri;
39 $this->method = $method;
40
41 array_walk_recursive($parameters, static function (&$value) {
42 $value = (string) $value;
43 });
44
45 $this->parameters = $parameters;
46 $this->files = $files;
47 $this->cookies = $cookies;
48 $this->server = $server;
49 $this->content = $content;
50 }
51
52 /**
53 * Gets the request URI.
54 *
55 * @return string
56 */
57 public function getUri()
58 {
59 return $this->uri;
60 }
61
62 /**
63 * Gets the request HTTP method.
64 *
65 * @return string
66 */
67 public function getMethod()
68 {
69 return $this->method;
70 }
71
72 /**
73 * Gets the request parameters.
74 *
75 * @return array
76 */
77 public function getParameters()
78 {
79 return $this->parameters;
80 }
81
82 /**
83 * Gets the request server files.
84 *
85 * @return array
86 */
87 public function getFiles()
88 {
89 return $this->files;
90 }
91
92 /**
93 * Gets the request cookies.
94 *
95 * @return array
96 */
97 public function getCookies()
98 {
99 return $this->cookies;
100 }
101
102 /**
103 * Gets the request server parameters.
104 *
105 * @return array
106 */
107 public function getServer()
108 {
109 return $this->server;
110 }
111
112 /**
113 * Gets the request raw body data.
114 *
115 * @return string|null
116 */
117 public function getContent()
118 {
119 return $this->content;
120 }
121 }
122