ConstraintViolationListNormalizer
in package
implements
NormalizerInterface, CacheableSupportsMethodInterface
A normalizer that normalizes a ConstraintViolationListInterface instance.
Tags
Interfaces, Classes, Traits and Enums
- NormalizerInterface
- CacheableSupportsMethodInterface
- Marker interface for normalizers and denormalizers that use only the type and the format in their supports*() methods.
Table of Contents
- INSTANCE = 'instance'
- STATUS = 'status'
- TITLE = 'title'
- TYPE = 'type'
- $defaultContext : mixed
- $nameConverter : mixed
- __construct() : mixed
- hasCacheableSupportsMethod() : bool
- normalize() : array<string|int, mixed>
- Normalizes an object into a set of arrays/scalars.
- supportsNormalization() : bool
- Checks whether the given class is supported for normalization by this normalizer.
Constants
INSTANCE
public
mixed
INSTANCE
= 'instance'
STATUS
public
mixed
STATUS
= 'status'
TITLE
public
mixed
TITLE
= 'title'
TYPE
public
mixed
TYPE
= 'type'
Properties
$defaultContext
private
mixed
$defaultContext
$nameConverter
private
mixed
$nameConverter
Methods
__construct()
public
__construct([array<string|int, mixed> $defaultContext = [] ][, NameConverterInterface $nameConverter = null ]) : mixed
Parameters
- $defaultContext : array<string|int, mixed> = []
- $nameConverter : NameConverterInterface = null
Return values
mixed —hasCacheableSupportsMethod()
public
hasCacheableSupportsMethod() : bool
Return values
bool —normalize()
Normalizes an object into a set of arrays/scalars.
public
normalize(mixed $object[, mixed $format = null ][, array<string|int, mixed> $context = [] ]) : array<string|int, mixed>
Parameters
- $object : mixed
-
Object to normalize
- $format : mixed = null
-
Format the normalization result will be encoded as
- $context : array<string|int, mixed> = []
-
Context options for the normalizer
Return values
array<string|int, mixed> —supportsNormalization()
Checks whether the given class is supported for normalization by this normalizer.
public
supportsNormalization(mixed $data[, mixed $format = null ]) : bool
Parameters
- $data : mixed
-
Data to normalize
- $format : mixed = null
-
The format being (de-)serialized from or into