PHP Класс WoohooLabs\Yin\JsonApi\Response\AbstractResponder

Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$exceptionFactory WoohooLabs\Yin\JsonApi\Exception\ExceptionFactoryInterface
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
$response Psr\Http\Message\ResponseInterface
$serializer WoohooLabs\Yin\JsonApi\Serializer\SerializerInterface

Открытые методы

Метод Описание
__construct ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, Psr\Http\Message\ResponseInterface $response, WoohooLabs\Yin\JsonApi\Exception\ExceptionFactoryInterface $exceptionFactory, WoohooLabs\Yin\JsonApi\Serializer\SerializerInterface $serializer )

Защищенные методы

Метод Описание
getDocumentMetaResponse ( AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
getDocumentRelationshipMetaResponse ( string $relationshipName, AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
getDocumentRelationshipResponse ( string $relationshipName, AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
getDocumentResourceResponse ( AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
getErrorResponse ( Psr\Http\Message\ResponseInterface $response, AbstractErrorDocument $document, array $errors, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface

Описание методов

__construct() публичный Метод

public __construct ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, Psr\Http\Message\ResponseInterface $response, WoohooLabs\Yin\JsonApi\Exception\ExceptionFactoryInterface $exceptionFactory, WoohooLabs\Yin\JsonApi\Serializer\SerializerInterface $serializer )
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
$response Psr\Http\Message\ResponseInterface
$exceptionFactory WoohooLabs\Yin\JsonApi\Exception\ExceptionFactoryInterface
$serializer WoohooLabs\Yin\JsonApi\Serializer\SerializerInterface

getDocumentMetaResponse() защищенный Метод

protected getDocumentMetaResponse ( AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
$document WoohooLabs\Yin\JsonApi\Document\AbstractSuccessfulDocument
$domainObject mixed
$statusCode integer
$additionalMeta array
Результат Psr\Http\Message\ResponseInterface

getDocumentRelationshipMetaResponse() защищенный Метод

protected getDocumentRelationshipMetaResponse ( string $relationshipName, AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
$relationshipName string
$document WoohooLabs\Yin\JsonApi\Document\AbstractSuccessfulDocument
$domainObject mixed
$statusCode integer
$additionalMeta array
Результат Psr\Http\Message\ResponseInterface

getDocumentRelationshipResponse() защищенный Метод

protected getDocumentRelationshipResponse ( string $relationshipName, AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
$relationshipName string
$document WoohooLabs\Yin\JsonApi\Document\AbstractSuccessfulDocument
$domainObject mixed
$statusCode integer
$additionalMeta array
Результат Psr\Http\Message\ResponseInterface

getDocumentResourceResponse() защищенный Метод

protected getDocumentResourceResponse ( AbstractSuccessfulDocument $document, mixed $domainObject, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
$document WoohooLabs\Yin\JsonApi\Document\AbstractSuccessfulDocument
$domainObject mixed
$statusCode integer
$additionalMeta array
Результат Psr\Http\Message\ResponseInterface

getErrorResponse() защищенный Метод

protected getErrorResponse ( Psr\Http\Message\ResponseInterface $response, AbstractErrorDocument $document, array $errors, integer $statusCode, array $additionalMeta = [] ) : Psr\Http\Message\ResponseInterface
$response Psr\Http\Message\ResponseInterface
$document WoohooLabs\Yin\JsonApi\Document\AbstractErrorDocument
$errors array
$statusCode integer
$additionalMeta array
Результат Psr\Http\Message\ResponseInterface $response

Описание свойств

$exceptionFactory защищенное свойство

protected ExceptionFactoryInterface,WoohooLabs\Yin\JsonApi\Exception $exceptionFactory
Результат WoohooLabs\Yin\JsonApi\Exception\ExceptionFactoryInterface

$request защищенное свойство

protected RequestInterface,WoohooLabs\Yin\JsonApi\Request $request
Результат WoohooLabs\Yin\JsonApi\Request\RequestInterface

$response защищенное свойство

protected ResponseInterface,Psr\Http\Message $response
Результат Psr\Http\Message\ResponseInterface

$serializer защищенное свойство

protected SerializerInterface,WoohooLabs\Yin\JsonApi\Serializer $serializer
Результат WoohooLabs\Yin\JsonApi\Serializer\SerializerInterface