@@ -860,8 +860,6 @@ you indicate that you're expecting an array instead of a single object.
860
860
The ``XmlEncoder ``
861
861
------------------
862
862
863
- This encoder transforms arrays into XML and vice versa.
864
-
865
863
This encoder transforms arrays into XML and vice versa. For example, take an
866
864
object normalized as following::
867
865
@@ -888,34 +886,33 @@ The array keys beginning with ``@`` are considered XML attributes::
888
886
// <foo bar="value" />
889
887
// </response>
890
888
891
- Contex
892
- ~~~~~~
893
-
894
- The context param is an array of additional options for the XmlEncoder.
889
+ Context
890
+ ~~~~~~~
895
891
896
- It must be defined while calling the XmlEncoder encode() method::
892
+ The ``encode() `` method defines a third optional parameter called ``context ``
893
+ which defines the configuration options for the XmlEncoder an associative array::
897
894
898
895
$xmlEncoder->encode($array, 'xml', $context);
899
896
900
- ** Available params: **
897
+ These are the options available:
901
898
902
899
``xml_format_output ``
903
- If set to true, format the output XML with line break and indentation
900
+ If set to true, formats the generated XML with line breaks and indentation.
904
901
905
902
``xml_version ``
906
- Change the XML version attribute
903
+ Sets the XML version attribute (default: `` 1.1 ``).
907
904
908
905
``xml_encoding ``
909
- Change the XML encoding attribute
906
+ Sets the XML encoding attribute (default: `` utf-8 ``).
910
907
911
908
``xml_standalone ``
912
- Add standalone attribute in XML output
909
+ Adds standalone attribute in the generated XML (default: `` true ``).
913
910
914
911
``xml_root_node_name ``
915
- Change the root node name (default: response)
912
+ Sets the root node name (default: `` response ``).
916
913
917
914
``remove_empty_tags ``
918
- If set to true, remove all empty tags in the XML output
915
+ If set to true, removes all empty tags in the generated XML.
919
916
920
917
Recursive Denormalization and Type Safety
921
918
-----------------------------------------
0 commit comments