Copied!

Normalizes a {@see \BackedEnum} enumeration to a string or an integer.

CloneableFinalInstantiable
Constants
public Symfony\Component\Serializer\Normalizer\BackedEnumNormalizer::ALLOW_INVALID_VALUES = 'allow_invalid_values'
 

If true, will denormalize any invalid value into null.

public Symfony\Component\Serializer\Normalizer\DenormalizerInterface::COLLECT_DENORMALIZATION_ERRORS = 'collect_denormalization_errors'
Methods
public denormalize(?mixed $data, string $type, ?string $format = NULL, array $context = []) : ?mixed
 
  • throws \NotNormalizableValueException
public getSupportedTypes(?string $format) : array
public normalize(?mixed $object, ?string $format = NULL, array $context = []) : string|int
public supportsDenormalization(?mixed $data, string $type, ?string $format = NULL, array $context = []) : bool
public supportsNormalization(?mixed $data, ?string $format = NULL, array $context = []) : bool
© 2024 Bruce Wells
Search Namespaces \ Classes
Configuration