-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
/
serializer.xml
176 lines (145 loc) · 9.41 KB
/
serializer.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
<?xml version="1.0" ?>
<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd">
<parameters>
<parameter key="serializer.mapping.cache.file">%kernel.cache_dir%/serialization.php</parameter>
<parameter key="serializer.mapping.cache.prefix" />
</parameters>
<services>
<defaults public="false" />
<service id="serializer" class="Symfony\Component\Serializer\Serializer" public="true">
<argument type="collection" />
<argument type="collection" />
</service>
<service id="Symfony\Component\Serializer\SerializerInterface" alias="serializer" />
<service id="Symfony\Component\Serializer\Normalizer\NormalizerInterface" alias="serializer" />
<service id="Symfony\Component\Serializer\Normalizer\DenormalizerInterface" alias="serializer" />
<service id="Symfony\Component\Serializer\Encoder\EncoderInterface" alias="serializer" />
<service id="Symfony\Component\Serializer\Encoder\DecoderInterface" alias="serializer" />
<service id="serializer.property_accessor" alias="property_accessor" />
<!-- Discriminator Map -->
<service id="serializer.mapping.class_discriminator_resolver" class="Symfony\Component\Serializer\Mapping\ClassDiscriminatorFromClassMetadata">
<argument type="service" id="serializer.mapping.class_metadata_factory" />
</service>
<service id="Symfony\Component\Serializer\Mapping\ClassDiscriminatorResolverInterface" alias="serializer.mapping.class_discriminator_resolver" />
<!-- Normalizer -->
<service id="serializer.normalizer.constraint_violation_list" class="Symfony\Component\Serializer\Normalizer\ConstraintViolationListNormalizer">
<argument type="collection" />
<argument type="service" id="serializer.name_converter.metadata_aware" />
<!-- Run before serializer.normalizer.object -->
<tag name="serializer.normalizer" priority="-915" />
</service>
<service id="serializer.normalizer.datetimezone" class="Symfony\Component\Serializer\Normalizer\DateTimeZoneNormalizer">
<!-- Run before serializer.normalizer.object -->
<tag name="serializer.normalizer" priority="-915" />
</service>
<service id="serializer.normalizer.dateinterval" class="Symfony\Component\Serializer\Normalizer\DateIntervalNormalizer">
<!-- Run before serializer.normalizer.object -->
<tag name="serializer.normalizer" priority="-915" />
</service>
<service id="serializer.normalizer.data_uri" class="Symfony\Component\Serializer\Normalizer\DataUriNormalizer">
<argument type="service" id="mime_types" on-invalid="null" />
<!-- Run before serializer.normalizer.object -->
<tag name="serializer.normalizer" priority="-920" />
</service>
<service id="serializer.normalizer.datetime" class="Symfony\Component\Serializer\Normalizer\DateTimeNormalizer">
<!-- Run before serializer.normalizer.object -->
<tag name="serializer.normalizer" priority="-910" />
</service>
<service id="serializer.normalizer.json_serializable" class="Symfony\Component\Serializer\Normalizer\JsonSerializableNormalizer">
<!-- Run before serializer.normalizer.object -->
<tag name="serializer.normalizer" priority="-900" />
</service>
<service id="serializer.normalizer.problem" class="Symfony\Component\Serializer\Normalizer\ProblemNormalizer">
<argument>%kernel.debug%</argument>
<!-- Run before serializer.normalizer.object -->
<tag name="serializer.normalizer" priority="-890" />
</service>
<service id="serializer.normalizer.object" class="Symfony\Component\Serializer\Normalizer\ObjectNormalizer">
<argument type="service" id="serializer.mapping.class_metadata_factory" />
<argument type="service" id="serializer.name_converter.metadata_aware" />
<argument type="service" id="serializer.property_accessor" />
<argument type="service" id="property_info" on-invalid="ignore" />
<argument type="service" id="serializer.mapping.class_discriminator_resolver" on-invalid="ignore" />
<argument>null</argument>
<argument type="collection" />
<!-- Run after all custom normalizers -->
<tag name="serializer.normalizer" priority="-1000" />
</service>
<service id="Symfony\Component\Serializer\Normalizer\ObjectNormalizer" alias="serializer.normalizer.object" />
<service id="serializer.denormalizer.array" class="Symfony\Component\Serializer\Normalizer\ArrayDenormalizer">
<!-- Run before the object normalizer -->
<tag name="serializer.normalizer" priority="-990" />
</service>
<!-- Loader -->
<service id="serializer.mapping.chain_loader" class="Symfony\Component\Serializer\Mapping\Loader\LoaderChain">
<argument type="collection" />
</service>
<!-- Class Metadata Factory -->
<service id="serializer.mapping.class_metadata_factory" class="Symfony\Component\Serializer\Mapping\Factory\ClassMetadataFactory">
<argument type="service" id="serializer.mapping.chain_loader" />
<argument>null</argument>
</service>
<service id="Symfony\Component\Serializer\Mapping\Factory\ClassMetadataFactoryInterface" alias="serializer.mapping.class_metadata_factory" />
<!-- Cache -->
<service id="serializer.mapping.cache_warmer" class="Symfony\Bundle\FrameworkBundle\CacheWarmer\SerializerCacheWarmer">
<argument type="collection" /><!-- Loaders injected by the extension -->
<argument>%serializer.mapping.cache.file%</argument>
<tag name="kernel.cache_warmer" />
<tag name="container.no_preload" />
</service>
<service id="serializer.mapping.cache.symfony" class="Psr\Cache\CacheItemPoolInterface">
<factory class="Symfony\Component\Cache\Adapter\PhpArrayAdapter" method="create" />
<argument>%serializer.mapping.cache.file%</argument>
<argument type="service" id="cache.serializer" />
</service>
<service id="serializer.mapping.cache_class_metadata_factory" decorates="serializer.mapping.class_metadata_factory" class="Symfony\Component\Serializer\Mapping\Factory\CacheClassMetadataFactory">
<argument type="service" id="serializer.mapping.cache_class_metadata_factory.inner" />
<argument type="service" id="serializer.mapping.cache.symfony" />
</service>
<!-- Encoders -->
<service id="serializer.encoder.xml" class="Symfony\Component\Serializer\Encoder\XmlEncoder">
<tag name="serializer.encoder" />
</service>
<service id="serializer.encoder.json" class="Symfony\Component\Serializer\Encoder\JsonEncoder">
<tag name="serializer.encoder" />
</service>
<service id="serializer.encoder.yaml" class="Symfony\Component\Serializer\Encoder\YamlEncoder">
<tag name="serializer.encoder" />
</service>
<service id="serializer.encoder.csv" class="Symfony\Component\Serializer\Encoder\CsvEncoder">
<tag name="serializer.encoder" />
</service>
<!-- Name converter -->
<service id="serializer.name_converter.camel_case_to_snake_case" class="Symfony\Component\Serializer\NameConverter\CamelCaseToSnakeCaseNameConverter" />
<service id="serializer.name_converter.metadata_aware" class="Symfony\Component\Serializer\NameConverter\MetadataAwareNameConverter" >
<argument type="service" id="serializer.mapping.class_metadata_factory"/>
</service>
<!-- PropertyInfo extractor -->
<service id="property_info.serializer_extractor" class="Symfony\Component\PropertyInfo\Extractor\SerializerExtractor">
<argument type="service" id="serializer.mapping.class_metadata_factory" />
<tag name="property_info.list_extractor" priority="-999" />
</service>
<!-- ErrorRenderer integration -->
<service id="error_renderer" alias="error_renderer.serializer" />
<service id="error_renderer.serializer" alias="error_handler.error_renderer.serializer" />
<service id="error_handler.error_renderer.serializer" class="Symfony\Component\ErrorHandler\ErrorRenderer\SerializerErrorRenderer">
<argument type="service" id="serializer" />
<argument type="service">
<service>
<factory class="Symfony\Component\ErrorHandler\ErrorRenderer\SerializerErrorRenderer" method="getPreferredFormat" />
<argument type="service" id="request_stack" />
</service>
</argument>
<argument type="service" id="error_renderer.html" />
<argument type="service">
<service>
<factory class="Symfony\Component\ErrorHandler\ErrorRenderer\HtmlErrorRenderer" method="isDebug" />
<argument type="service" id="request_stack" />
<argument>%kernel.debug%</argument>
</service>
</argument>
</service>
</services>
</container>