@@ -45,95 +45,156 @@ public function __construct($version = '1.1', array $headers = [], StreamInterfa
45
45
$ this ->attributes = $ attributes ;
46
46
}
47
47
48
- public function getRequestTarget ()
48
+ public function getRequestTarget (): string
49
49
{
50
50
return $ this ->requestTarget ;
51
51
}
52
52
53
+ /**
54
+ * {@inheritdoc}
55
+ *
56
+ * @return static
57
+ */
53
58
public function withRequestTarget ($ requestTarget )
54
59
{
55
60
throw new \BadMethodCallException ('Not implemented. ' );
56
61
}
57
62
58
- public function getMethod ()
63
+ public function getMethod (): string
59
64
{
60
65
return $ this ->method ;
61
66
}
62
67
68
+ /**
69
+ * {@inheritdoc}
70
+ *
71
+ * @return static
72
+ */
63
73
public function withMethod ($ method )
64
74
{
75
+ throw new \BadMethodCallException ('Not implemented. ' );
65
76
}
66
77
78
+ /**
79
+ * {@inheritdoc}
80
+ *
81
+ * @return UriInterface
82
+ */
67
83
public function getUri ()
68
84
{
69
85
return $ this ->uri ;
70
86
}
71
87
88
+ /**
89
+ * {@inheritdoc}
90
+ *
91
+ * @return static
92
+ */
72
93
public function withUri (UriInterface $ uri , $ preserveHost = false )
73
94
{
74
95
throw new \BadMethodCallException ('Not implemented. ' );
75
96
}
76
97
77
- public function getServerParams ()
98
+ public function getServerParams (): array
78
99
{
79
100
return $ this ->server ;
80
101
}
81
102
82
- public function getCookieParams ()
103
+ public function getCookieParams (): array
83
104
{
84
105
return $ this ->cookies ;
85
106
}
86
107
108
+ /**
109
+ * {@inheritdoc}
110
+ *
111
+ * @return static
112
+ */
87
113
public function withCookieParams (array $ cookies )
88
114
{
89
115
throw new \BadMethodCallException ('Not implemented. ' );
90
116
}
91
117
92
- public function getQueryParams ()
118
+ public function getQueryParams (): array
93
119
{
94
120
return $ this ->query ;
95
121
}
96
122
123
+ /**
124
+ * {@inheritdoc}
125
+ *
126
+ * @return static
127
+ */
97
128
public function withQueryParams (array $ query )
98
129
{
99
130
throw new \BadMethodCallException ('Not implemented. ' );
100
131
}
101
132
102
- public function getUploadedFiles ()
133
+ public function getUploadedFiles (): array
103
134
{
104
135
return $ this ->uploadedFiles ;
105
136
}
106
137
138
+ /**
139
+ * {@inheritdoc}
140
+ *
141
+ * @return static
142
+ */
107
143
public function withUploadedFiles (array $ uploadedFiles )
108
144
{
109
145
throw new \BadMethodCallException ('Not implemented. ' );
110
146
}
111
147
148
+ /**
149
+ * {@inheritdoc}
150
+ *
151
+ * @return array|object|null
152
+ */
112
153
public function getParsedBody ()
113
154
{
114
155
return $ this ->data ;
115
156
}
116
157
158
+ /**
159
+ * {@inheritdoc}
160
+ *
161
+ * @return static
162
+ */
117
163
public function withParsedBody ($ data )
118
164
{
119
165
throw new \BadMethodCallException ('Not implemented. ' );
120
166
}
121
167
122
- public function getAttributes ()
168
+ public function getAttributes (): array
123
169
{
124
170
return $ this ->attributes ;
125
171
}
126
172
173
+ /**
174
+ * {@inheritdoc}
175
+ *
176
+ * @return mixed
177
+ */
127
178
public function getAttribute ($ name , $ default = null )
128
179
{
129
- return isset ( $ this ->attributes [$ name ]) ? $ this -> attributes [ $ name ] : $ default ;
180
+ return $ this ->attributes [$ name ] ?? $ default ;
130
181
}
131
182
183
+ /**
184
+ * {@inheritdoc}
185
+ *
186
+ * @return static
187
+ */
132
188
public function withAttribute ($ name , $ value )
133
189
{
134
190
throw new \BadMethodCallException ('Not implemented. ' );
135
191
}
136
192
193
+ /**
194
+ * {@inheritdoc}
195
+ *
196
+ * @return static
197
+ */
137
198
public function withoutAttribute ($ name )
138
199
{
139
200
throw new \BadMethodCallException ('Not implemented. ' );
0 commit comments