1 | <?php |
||
14 | final class Psr17Factory implements RequestFactoryInterface, ResponseFactoryInterface, ServerRequestFactoryInterface, StreamFactoryInterface, UploadedFileFactoryInterface, UriFactoryInterface |
||
15 | { |
||
16 | 7 | public function createRequest(string $method, $uri): RequestInterface |
|
20 | |||
21 | 4 | public function createResponse(int $code = 200, string $reasonPhrase = ''): ResponseInterface |
|
25 | |||
26 | 6 | public function createStream(string $content = ''): StreamInterface |
|
30 | |||
31 | 1 | public function createStreamFromFile(string $filename, string $mode = 'r'): StreamInterface |
|
40 | |||
41 | 1 | public function createStreamFromResource($resource): StreamInterface |
|
45 | |||
46 | 12 | public function createUploadedFile(StreamInterface $stream, int $size = null, int $error = \UPLOAD_ERR_OK, string $clientFilename = null, string $clientMediaType = null): UploadedFileInterface |
|
54 | |||
55 | 13 | public function createUri(string $uri = ''): UriInterface |
|
59 | |||
60 | 23 | public function createServerRequest(string $method, $uri, array $serverParams = []): ServerRequestInterface |
|
64 | } |
||
65 |
This check looks at variables that have been passed in as parameters and are passed out again to other methods.
If the outgoing method call has stricter type requirements than the method itself, an issue is raised.
An additional type check may prevent trouble.