Class

eZ\Publish\Core\REST\Common\Input\ParsingDispatcher

class ParsingDispatcher

Parsing dispatcher.

Methods

__construct(array $parsers = array())

Construct from optional parsers array.

addParser(string $mediaType, Parser $parser)

Adds another parser for the given Content Type.

ValueObject parse(array $data, string $mediaType)

Parses the given $data according to $mediaType.

Details

at line 41
public __construct(array $parsers = array())

Construct from optional parsers array.

Parameters

array $parsers

at line 54
public addParser(string $mediaType, Parser $parser)

Adds another parser for the given Content Type.

Parameters

string $mediaType
Parser $parser

at line 68
public ValueObject parse(array $data, string $mediaType)

Parses the given $data according to $mediaType.

Parameters

array $data
string $mediaType

Return Value

ValueObject