MessageFactory
in package
implements
MessageFactoryInterface
FinalYes
Table of Contents
Interfaces
Properties
- $requestFactory : RequestFactoryInterface
- $responseFactory : ResponseFactoryInterface
- $serverRequestFactory : ServerRequestFactoryInterface
Methods
- __construct() : mixed
- create() : self
- createRequest() : RequestInterface
- createResponse() : ResponseInterface
- createServerRequest() : ServerRequestInterface
Properties
$requestFactory read-only
private
RequestFactoryInterface
$requestFactory
$responseFactory read-only
private
ResponseFactoryInterface
$responseFactory
$serverRequestFactory read-only
private
ServerRequestFactoryInterface
$serverRequestFactory
Methods
__construct()
public
__construct(RequestFactoryInterface $requestFactory, ResponseFactoryInterface $responseFactory, ServerRequestFactoryInterface $serverRequestFactory) : mixed
Parameters
- $requestFactory : RequestFactoryInterface
- $responseFactory : ResponseFactoryInterface
- $serverRequestFactory : ServerRequestFactoryInterface
create()
public
static create(RequestFactoryInterface $requestFactory, ResponseFactoryInterface $responseFactory, ServerRequestFactoryInterface $serverRequestFactory) : self
Parameters
- $requestFactory : RequestFactoryInterface
- $responseFactory : ResponseFactoryInterface
- $serverRequestFactory : ServerRequestFactoryInterface
Return values
selfcreateRequest()
public
createRequest(string $method, mixed $uri) : RequestInterface
Parameters
- $method : string
- $uri : mixed
Return values
RequestInterfacecreateResponse()
public
createResponse([int $code = 200 ][, string $reasonPhrase = '' ]) : ResponseInterface
Parameters
- $code : int = 200
- $reasonPhrase : string = ''
Return values
ResponseInterfacecreateServerRequest()
public
createServerRequest(string $method, mixed $uri[, array<string|int, mixed> $serverParams = [] ]) : ServerRequestInterface
Parameters
- $method : string
- $uri : mixed
- $serverParams : array<string|int, mixed> = []