@@ -321,27 +321,28 @@ The YAML specification defines some tags to set the type of any data explicitly:
321321 Pz7Y6OjuDg4J+fn5OTk6enp
322322 56enmleECcgggoBADs=
323323
324- Symfony Specific Tags
325- ~~~~~~~~~~~~~~~~~~~~~
324+ Symfony Specific Features
325+ ~~~~~~~~~~~~~~~~~~~~~~~~~
326326
327- The YAML component provides a few additional tags that brings a few
328- features when parsed in your PHP code :
327+ The Yaml component provides some additional features that are not part of the
328+ official YAML specification but are useful in Symfony applications :
329329
330- * ``!php/const `` allows to use a constant name defined in a PHP file . This
331- tag takes a constant FQCN as its argument:
330+ * ``!php/const `` allows to get the value of a PHP constant . This tag takes the
331+ fully-qualified class name of the constant as its argument:
332332
333- .. code-block :: yaml
333+ .. code-block :: yaml
334334
335- data :
336- page_limit : !php/const App\Pagination\Paginator::PAGE_LIMIT
335+ data :
336+ page_limit : !php/const App\Pagination\Paginator::PAGE_LIMIT
337337
338338 * ``!php/object `` allows to pass the serialized representation of a PHP
339- object, which will be deserialized when the parsing is done:
339+ object (created with the `serialize() `_ function), which will be deserialized
340+ when parsing the YAML file:
340341
341- .. code-block :: yaml
342+ .. code-block :: yaml
342343
343- data :
344- my_object : !php/object 'O:8:"stdClass":1:{s:3:"bar";i:2;}'
344+ data :
345+ my_object : !php/object 'O:8:"stdClass":1:{s:3:"bar";i:2;}'
345346
346347 Unsupported YAML Features
347348~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -360,3 +361,4 @@ The following YAML features are not supported by the Symfony Yaml component:
360361
361362.. _`YAML 1.2 version specification` : https://yaml.org/spec/1.2/spec.html
362363.. _`ISO-8601` : https://www.iso.org/iso-8601-date-and-time-format.html
364+ .. _`serialize()` : https://www.php.net/manual/en/function.serialize.php
0 commit comments