class PhpFormat implements FormatInterface (View source)

PHP class format handler for Structure

Methods

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

Converts an object into a php class string.

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

Parse a PHP class formatted string and convert it into an object.

Details

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

Converts an object into a php class string.

  • NOTE: Only one depth level is supported.

Parameters

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

Return Value

string Formatted string.

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

Parse a PHP class 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