PHP Class WoohooLabs\Yin\JsonApi\Exception\DefaultExceptionFactory

Inheritance: implements WoohooLabs\Yin\JsonApi\Exception\ExceptionFactoryInterface
显示文件 Open project: woohoolabs/yin

Public Methods

Method Description
createApplicationErrorException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : ApplicationError
createClientGeneratedIdAlreadyExistsException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $currentId ) : WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdAlreadyExists
createClientGeneratedIdNotSupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $currentId ) : WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdNotSupported
createClientGeneratedIdRequiredException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdRequired
createDataMemberMissingException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\DataMemberMissing
createFullReplacementProhibitedException ( $relationshipName ) : WoohooLabs\Yin\JsonApi\Exception\FullReplacementProhibited
createInclusionUnrecognizedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, array $unrecognizedInclusions ) : WoohooLabs\Yin\JsonApi\Exception\InclusionUnrecognized
createInclusionUnsupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\InclusionUnsupported
createMediaTypeUnacceptableException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $mediaTypeName ) : WoohooLabs\Yin\JsonApi\Exception\MediaTypeUnacceptable
createMediaTypeUnsupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $mediaTypeName ) : WoohooLabs\Yin\JsonApi\Exception\MediaTypeUnsupported
createQueryParamUnrecognizedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $queryParamName ) : WoohooLabs\Yin\JsonApi\Exception\QueryParamUnrecognized
createRelationshipNotExists ( string $relationship ) : Exception
createRelationshipTypeInappropriateException ( $relationshipName, $currentRelationshipType, $expectedRelationshipType ) : WoohooLabs\Yin\JsonApi\Exception\RelationshipTypeInappropriate
createRemovalProhibitedException ( $relationshipName ) : WoohooLabs\Yin\JsonApi\Exception\RemovalProhibited
createRequestBodyInvalidJsonApiException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, array $validationErrors, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\RequestBodyInvalidJsonApi
createRequestBodyInvalidJsonException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $lintMessage, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\RequestBodyInvalidJson
createResourceIdInvalidException ( $id ) : WoohooLabs\Yin\JsonApi\Exception\ResourceIdInvalid
createResourceIdMissingException ( ) : WoohooLabs\Yin\JsonApi\Exception\ResourceIdMissing
createResourceIdentifierIdMissing ( array $resourceIdentifier ) : Exception
createResourceIdentifierTypeMissing ( array $resourceIdentifier ) : Exception
createResourceNotFoundException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\ResourceNotFound
createResourceTypeMissingException ( ) : WoohooLabs\Yin\JsonApi\Exception\ResourceTypeMissing
createResourceTypeUnacceptableException ( $currentType, array $acceptedTypes ) : WoohooLabs\Yin\JsonApi\Exception\ResourceTypeUnacceptable
createResponseBodyInvalidJsonApiException ( Psr\Http\Message\ResponseInterface $response, array $validationErrors, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\ResponseBodyInvalidJsonApi
createResponseBodyInvalidJsonException ( Psr\Http\Message\ResponseInterface $response, $lintMessage, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\ResponseBodyInvalidJson
createSortParamUnrecognizedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $paramName ) : WoohooLabs\Yin\JsonApi\Exception\SortParamUnrecognized
createSortingUnsupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\SortingUnsupported

Method Details

createApplicationErrorException() public method

public createApplicationErrorException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : ApplicationError
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return ApplicationError

createClientGeneratedIdAlreadyExistsException() public method

public createClientGeneratedIdAlreadyExistsException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $currentId ) : WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdAlreadyExists
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdAlreadyExists

createClientGeneratedIdNotSupportedException() public method

public createClientGeneratedIdNotSupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $currentId ) : WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdNotSupported
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdNotSupported

createClientGeneratedIdRequiredException() public method

public createClientGeneratedIdRequiredException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdRequired
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\ClientGeneratedIdRequired

createDataMemberMissingException() public method

public createDataMemberMissingException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\DataMemberMissing
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\DataMemberMissing

createFullReplacementProhibitedException() public method

public createFullReplacementProhibitedException ( $relationshipName ) : WoohooLabs\Yin\JsonApi\Exception\FullReplacementProhibited
return WoohooLabs\Yin\JsonApi\Exception\FullReplacementProhibited

createInclusionUnrecognizedException() public method

public createInclusionUnrecognizedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, array $unrecognizedInclusions ) : WoohooLabs\Yin\JsonApi\Exception\InclusionUnrecognized
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
$unrecognizedInclusions array
return WoohooLabs\Yin\JsonApi\Exception\InclusionUnrecognized

createInclusionUnsupportedException() public method

public createInclusionUnsupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\InclusionUnsupported
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\InclusionUnsupported

createMediaTypeUnacceptableException() public method

public createMediaTypeUnacceptableException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $mediaTypeName ) : WoohooLabs\Yin\JsonApi\Exception\MediaTypeUnacceptable
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\MediaTypeUnacceptable

createMediaTypeUnsupportedException() public method

public createMediaTypeUnsupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $mediaTypeName ) : WoohooLabs\Yin\JsonApi\Exception\MediaTypeUnsupported
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\MediaTypeUnsupported

createQueryParamUnrecognizedException() public method

public createQueryParamUnrecognizedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $queryParamName ) : WoohooLabs\Yin\JsonApi\Exception\QueryParamUnrecognized
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\QueryParamUnrecognized

createRelationshipNotExists() public method

public createRelationshipNotExists ( string $relationship ) : Exception
$relationship string
return Exception

createRelationshipTypeInappropriateException() public method

public createRelationshipTypeInappropriateException ( $relationshipName, $currentRelationshipType, $expectedRelationshipType ) : WoohooLabs\Yin\JsonApi\Exception\RelationshipTypeInappropriate
return WoohooLabs\Yin\JsonApi\Exception\RelationshipTypeInappropriate

createRemovalProhibitedException() public method

public createRemovalProhibitedException ( $relationshipName ) : WoohooLabs\Yin\JsonApi\Exception\RemovalProhibited
return WoohooLabs\Yin\JsonApi\Exception\RemovalProhibited

createRequestBodyInvalidJsonApiException() public method

public createRequestBodyInvalidJsonApiException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, array $validationErrors, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\RequestBodyInvalidJsonApi
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
$validationErrors array
return WoohooLabs\Yin\JsonApi\Exception\RequestBodyInvalidJsonApi

createRequestBodyInvalidJsonException() public method

public createRequestBodyInvalidJsonException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $lintMessage, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\RequestBodyInvalidJson
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\RequestBodyInvalidJson

createResourceIdInvalidException() public method

public createResourceIdInvalidException ( $id ) : WoohooLabs\Yin\JsonApi\Exception\ResourceIdInvalid
return WoohooLabs\Yin\JsonApi\Exception\ResourceIdInvalid

createResourceIdMissingException() public method

public createResourceIdMissingException ( ) : WoohooLabs\Yin\JsonApi\Exception\ResourceIdMissing
return WoohooLabs\Yin\JsonApi\Exception\ResourceIdMissing

createResourceIdentifierIdMissing() public method

public createResourceIdentifierIdMissing ( array $resourceIdentifier ) : Exception
$resourceIdentifier array
return Exception

createResourceIdentifierTypeMissing() public method

public createResourceIdentifierTypeMissing ( array $resourceIdentifier ) : Exception
$resourceIdentifier array
return Exception

createResourceNotFoundException() public method

public createResourceNotFoundException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\ResourceNotFound
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\ResourceNotFound

createResourceTypeMissingException() public method

public createResourceTypeMissingException ( ) : WoohooLabs\Yin\JsonApi\Exception\ResourceTypeMissing
return WoohooLabs\Yin\JsonApi\Exception\ResourceTypeMissing

createResourceTypeUnacceptableException() public method

public createResourceTypeUnacceptableException ( $currentType, array $acceptedTypes ) : WoohooLabs\Yin\JsonApi\Exception\ResourceTypeUnacceptable
$acceptedTypes array
return WoohooLabs\Yin\JsonApi\Exception\ResourceTypeUnacceptable

createResponseBodyInvalidJsonApiException() public method

public createResponseBodyInvalidJsonApiException ( Psr\Http\Message\ResponseInterface $response, array $validationErrors, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\ResponseBodyInvalidJsonApi
$response Psr\Http\Message\ResponseInterface
$validationErrors array
return WoohooLabs\Yin\JsonApi\Exception\ResponseBodyInvalidJsonApi

createResponseBodyInvalidJsonException() public method

public createResponseBodyInvalidJsonException ( Psr\Http\Message\ResponseInterface $response, $lintMessage, $includeOriginalBody ) : WoohooLabs\Yin\JsonApi\Exception\ResponseBodyInvalidJson
$response Psr\Http\Message\ResponseInterface
return WoohooLabs\Yin\JsonApi\Exception\ResponseBodyInvalidJson

createSortParamUnrecognizedException() public method

public createSortParamUnrecognizedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request, $paramName ) : WoohooLabs\Yin\JsonApi\Exception\SortParamUnrecognized
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\SortParamUnrecognized

createSortingUnsupportedException() public method

public createSortingUnsupportedException ( WoohooLabs\Yin\JsonApi\Request\RequestInterface $request ) : WoohooLabs\Yin\JsonApi\Exception\SortingUnsupported
$request WoohooLabs\Yin\JsonApi\Request\RequestInterface
return WoohooLabs\Yin\JsonApi\Exception\SortingUnsupported