annotate vendor/symfony/serializer/CHANGELOG.md @ 19:fa3358dc1485 tip

Add ndrum files
author Chris Cannam
date Wed, 28 Aug 2019 13:14:47 +0100
parents 1fec387a4317
children
rev   line source
Chris@0 1 CHANGELOG
Chris@0 2 =========
Chris@0 3
Chris@14 4 3.4.0
Chris@14 5 -----
Chris@14 6
Chris@14 7 * added `AbstractObjectNormalizer::DISABLE_TYPE_ENFORCEMENT` context option
Chris@14 8 to disable throwing an `UnexpectedValueException` on a type mismatch
Chris@14 9 * added support for serializing `DateInterval` objects
Chris@14 10 * added getter for extra attributes in `ExtraAttributesException`
Chris@14 11 * improved `CsvEncoder` to handle variable nested structures
Chris@14 12 * CSV headers can be passed to the `CsvEncoder` via the `csv_headers` serialization context variable
Chris@14 13 * added `$context` when checking for encoding, decoding and normalizing in `Serializer`
Chris@14 14
Chris@14 15 3.3.0
Chris@14 16 -----
Chris@14 17
Chris@14 18 * added `SerializerPass`
Chris@14 19
Chris@0 20 3.1.0
Chris@0 21 -----
Chris@0 22
Chris@0 23 * added support for serializing objects that implement `JsonSerializable`
Chris@0 24 * added the `DenormalizerAwareTrait` and `NormalizerAwareTrait` traits to
Chris@0 25 support normalizer/denormalizer awareness
Chris@0 26 * added the `DenormalizerAwareInterface` and `NormalizerAwareInterface`
Chris@0 27 interfaces to support normalizer/denormalizer awareness
Chris@0 28 * added a PSR-6 compatible adapter for caching metadata
Chris@0 29 * added a `MaxDepth` option to limit the depth of the object graph when
Chris@0 30 serializing objects
Chris@0 31 * added support for serializing `SplFileInfo` objects
Chris@0 32 * added support for serializing objects that implement `DateTimeInterface`
Chris@0 33 * added `AbstractObjectNormalizer` as a base class for normalizers that deal
Chris@0 34 with objects
Chris@0 35 * added support to relation deserialization
Chris@0 36
Chris@0 37 2.7.0
Chris@0 38 -----
Chris@0 39
Chris@0 40 * added support for serialization and deserialization groups including
Chris@0 41 annotations, XML and YAML mapping.
Chris@0 42 * added `AbstractNormalizer` to factorise code and ease normalizers development
Chris@0 43 * added circular references handling for `PropertyNormalizer`
Chris@0 44 * added support for a context key called `object_to_populate` in `AbstractNormalizer`
Chris@0 45 to reuse existing objects in the deserialization process
Chris@0 46 * added `NameConverterInterface` and `CamelCaseToSnakeCaseNameConverter`
Chris@0 47 * [DEPRECATION] `GetSetMethodNormalizer::setCamelizedAttributes()` and
Chris@0 48 `PropertyNormalizer::setCamelizedAttributes()` are replaced by
Chris@0 49 `CamelCaseToSnakeCaseNameConverter`
Chris@0 50 * [DEPRECATION] the `Exception` interface has been renamed to `ExceptionInterface`
Chris@0 51 * added `ObjectNormalizer` leveraging the `PropertyAccess` component to normalize
Chris@0 52 objects containing both properties and getters / setters / issers / hassers methods.
Chris@14 53 * added `xml_type_cast_attributes` context option for allowing users to opt-out of typecasting
Chris@14 54 xml attributes.
Chris@0 55
Chris@0 56 2.6.0
Chris@0 57 -----
Chris@0 58
Chris@0 59 * added a new serializer: `PropertyNormalizer`. Like `GetSetMethodNormalizer`,
Chris@0 60 this normalizer will map an object's properties to an array.
Chris@0 61 * added circular references handling for `GetSetMethodNormalizer`
Chris@0 62
Chris@0 63 2.5.0
Chris@0 64 -----
Chris@0 65
Chris@0 66 * added support for `is.*` getters in `GetSetMethodNormalizer`
Chris@0 67
Chris@0 68 2.4.0
Chris@0 69 -----
Chris@0 70
Chris@0 71 * added `$context` support for XMLEncoder.
Chris@0 72 * [DEPRECATION] JsonEncode and JsonDecode where modified to throw
Chris@0 73 an exception if error found. No need for get*Error() functions
Chris@0 74
Chris@0 75 2.3.0
Chris@0 76 -----
Chris@0 77
Chris@0 78 * added `GetSetMethodNormalizer::setCamelizedAttributes` to allow calling
Chris@0 79 camel cased methods for underscored properties
Chris@0 80
Chris@0 81 2.2.0
Chris@0 82 -----
Chris@0 83
Chris@0 84 * [BC BREAK] All Serializer, Normalizer and Encoder interfaces have been
Chris@0 85 modified to include an optional `$context` array parameter.
Chris@0 86 * The XML Root name can now be configured with the `xml_root_name`
Chris@0 87 parameter in the context option to the `XmlEncoder`.
Chris@0 88 * Options to `json_encode` and `json_decode` can be passed through
Chris@0 89 the context options of `JsonEncode` and `JsonDecode` encoder/decoders.
Chris@0 90
Chris@0 91 2.1.0
Chris@0 92 -----
Chris@0 93
Chris@0 94 * added DecoderInterface::supportsDecoding(),
Chris@0 95 EncoderInterface::supportsEncoding()
Chris@0 96 * removed NormalizableInterface::denormalize(),
Chris@0 97 NormalizerInterface::denormalize(),
Chris@0 98 NormalizerInterface::supportsDenormalization()
Chris@0 99 * removed normalize() denormalize() encode() decode() supportsSerialization()
Chris@0 100 supportsDeserialization() supportsEncoding() supportsDecoding()
Chris@0 101 getEncoder() from SerializerInterface
Chris@0 102 * Serializer now implements NormalizerInterface, DenormalizerInterface,
Chris@0 103 EncoderInterface, DecoderInterface in addition to SerializerInterface
Chris@0 104 * added DenormalizableInterface and DenormalizerInterface
Chris@0 105 * [BC BREAK] changed `GetSetMethodNormalizer`'s key names from all lowercased
Chris@0 106 to camelCased (e.g. `mypropertyvalue` to `myPropertyValue`)
Chris@0 107 * [BC BREAK] convert the `item` XML tag to an array
Chris@0 108
Chris@0 109 ``` xml
Chris@0 110 <?xml version="1.0"?>
Chris@0 111 <response>
Chris@0 112 <item><title><![CDATA[title1]]></title></item><item><title><![CDATA[title2]]></title></item>
Chris@0 113 </response>
Chris@0 114 ```
Chris@0 115
Chris@0 116 Before:
Chris@0 117
Chris@0 118 Array()
Chris@0 119
Chris@0 120 After:
Chris@0 121
Chris@0 122 Array(
Chris@0 123 [item] => Array(
Chris@0 124 [0] => Array(
Chris@0 125 [title] => title1
Chris@0 126 )
Chris@0 127 [1] => Array(
Chris@0 128 [title] => title2
Chris@0 129 )
Chris@0 130 )
Chris@0 131 )