@@ -45,95 +45,156 @@ public function __construct($version = '1.1', array $headers = [], StreamInterfa
4545 $ this ->attributes = $ attributes ;
4646 }
4747
48- public function getRequestTarget ()
48+ public function getRequestTarget (): string
4949 {
5050 return $ this ->requestTarget ;
5151 }
5252
53+ /**
54+ * {@inheritdoc}
55+ *
56+ * @return static
57+ */
5358 public function withRequestTarget ($ requestTarget )
5459 {
5560 throw new \BadMethodCallException ('Not implemented. ' );
5661 }
5762
58- public function getMethod ()
63+ public function getMethod (): string
5964 {
6065 return $ this ->method ;
6166 }
6267
68+ /**
69+ * {@inheritdoc}
70+ *
71+ * @return static
72+ */
6373 public function withMethod ($ method )
6474 {
75+ throw new \BadMethodCallException ('Not implemented. ' );
6576 }
6677
78+ /**
79+ * {@inheritdoc}
80+ *
81+ * @return UriInterface
82+ */
6783 public function getUri ()
6884 {
6985 return $ this ->uri ;
7086 }
7187
88+ /**
89+ * {@inheritdoc}
90+ *
91+ * @return static
92+ */
7293 public function withUri (UriInterface $ uri , $ preserveHost = false )
7394 {
7495 throw new \BadMethodCallException ('Not implemented. ' );
7596 }
7697
77- public function getServerParams ()
98+ public function getServerParams (): array
7899 {
79100 return $ this ->server ;
80101 }
81102
82- public function getCookieParams ()
103+ public function getCookieParams (): array
83104 {
84105 return $ this ->cookies ;
85106 }
86107
108+ /**
109+ * {@inheritdoc}
110+ *
111+ * @return static
112+ */
87113 public function withCookieParams (array $ cookies )
88114 {
89115 throw new \BadMethodCallException ('Not implemented. ' );
90116 }
91117
92- public function getQueryParams ()
118+ public function getQueryParams (): array
93119 {
94120 return $ this ->query ;
95121 }
96122
123+ /**
124+ * {@inheritdoc}
125+ *
126+ * @return static
127+ */
97128 public function withQueryParams (array $ query )
98129 {
99130 throw new \BadMethodCallException ('Not implemented. ' );
100131 }
101132
102- public function getUploadedFiles ()
133+ public function getUploadedFiles (): array
103134 {
104135 return $ this ->uploadedFiles ;
105136 }
106137
138+ /**
139+ * {@inheritdoc}
140+ *
141+ * @return static
142+ */
107143 public function withUploadedFiles (array $ uploadedFiles )
108144 {
109145 throw new \BadMethodCallException ('Not implemented. ' );
110146 }
111147
148+ /**
149+ * {@inheritdoc}
150+ *
151+ * @return array|object|null
152+ */
112153 public function getParsedBody ()
113154 {
114155 return $ this ->data ;
115156 }
116157
158+ /**
159+ * {@inheritdoc}
160+ *
161+ * @return static
162+ */
117163 public function withParsedBody ($ data )
118164 {
119165 throw new \BadMethodCallException ('Not implemented. ' );
120166 }
121167
122- public function getAttributes ()
168+ public function getAttributes (): array
123169 {
124170 return $ this ->attributes ;
125171 }
126172
173+ /**
174+ * {@inheritdoc}
175+ *
176+ * @return mixed
177+ */
127178 public function getAttribute ($ name , $ default = null )
128179 {
129- return isset ( $ this ->attributes [$ name ]) ? $ this -> attributes [ $ name ] : $ default ;
180+ return $ this ->attributes [$ name ] ?? $ default ;
130181 }
131182
183+ /**
184+ * {@inheritdoc}
185+ *
186+ * @return static
187+ */
132188 public function withAttribute ($ name , $ value )
133189 {
134190 throw new \BadMethodCallException ('Not implemented. ' );
135191 }
136192
193+ /**
194+ * {@inheritdoc}
195+ *
196+ * @return static
197+ */
137198 public function withoutAttribute ($ name )
138199 {
139200 throw new \BadMethodCallException ('Not implemented. ' );
0 commit comments