For media types registered in $_handlers which include an 'decode' setting, decodes data
according to the specified media type.
public static decode ( string $type, mixed $data, array $options = [] ) : mixed | ||
$type | string | Specifies the media type into which `$data` will be encoded. This media type must have an `'encode'` setting specified in `Media::$_handlers`. |
$data | mixed | Arbitrary data you wish to encode. Note that some encoders can only handle arrays or objects. |
$options | array | Handler-specific options. |
return | mixed |