class XmlFormat implements FormatInterface (View source)

XML format handler for Structure.

Methods

static string
structToString(object $struct, array $options = array())

Converts an object into an XML formatted string.

static object
stringToStruct(string $data, array $options = array())

Parse a XML formatted string and convert it into an object.

Details

at line line 30
static string structToString(object $struct, array $options = array())

Converts an object into an XML formatted string.

  • If more than two levels of nested groups are necessary, since INI is not useful, XML or another format should be used.

Parameters

object $struct Data Source Object.
array $options An array of options for the formatter.

Return Value

string Formatted string.

at line line 54
static object stringToStruct(string $data, array $options = array())

Parse a XML formatted string and convert it into an object.

Parameters

string $data Formatted string
array $options An array of options for the formatter.

Return Value

object Data Object