PHP Class ApiPlatform\Core\Hal\Serializer\ItemNormalizer

Author: Kévin Dunglas ([email protected])
Inheritance: extends ApiPlatform\Core\Serializer\AbstractItemNormalizer, use trait ApiPlatform\Core\Serializer\ContextTrait
Show file Open project: api-platform/core Class Usage Examples

Public Methods

Method Description
denormalize ( $data, $class, $format = null, array $context = [] )
normalize ( $object, $format = null, array $context = [] )
supportsDenormalization ( $data, $type, $format = null )
supportsNormalization ( $data, $format = null )

Protected Methods

Method Description
getAttributes ( $object, $format, array $context )

Private Methods

Method Description
getComponents ( object $object, string $format = null, array $context ) : array Gets HAL components of the resource: states, links and embedded.
getHalCacheKey ( string $format = null, array $context ) : boolean | string Gets the cache key to use.
getRelationIri ( array | string $rel ) : string Gets the IRI of the given relation.
populateRelation ( array $data, object $object, string $format = null, array $context, array $components, string $type ) : array Populates _links and _embedded keys.

Method Details

denormalize() public method

public denormalize ( $data, $class, $format = null, array $context = [] )
$context array

getAttributes() protected method

protected getAttributes ( $object, $format, array $context )
$context array

normalize() public method

public normalize ( $object, $format = null, array $context = [] )
$context array

supportsDenormalization() public method

public supportsDenormalization ( $data, $type, $format = null )

supportsNormalization() public method

public supportsNormalization ( $data, $format = null )