@@ -5,11 +5,11 @@ |
||
5 | 5 | use Nathanmac\Utilities\Parser\Formats\BSON; |
6 | 6 | use Nathanmac\Utilities\Parser\Formats\FormatInterface; |
7 | 7 | use Nathanmac\Utilities\Parser\Formats\JSON; |
8 | +use Nathanmac\Utilities\Parser\Formats\MSGPack; |
|
8 | 9 | use Nathanmac\Utilities\Parser\Formats\QueryStr; |
9 | 10 | use Nathanmac\Utilities\Parser\Formats\Serialize; |
10 | 11 | use Nathanmac\Utilities\Parser\Formats\XML; |
11 | 12 | use Nathanmac\Utilities\Parser\Formats\YAML; |
12 | -use Nathanmac\Utilities\Parser\Formats\MSGPack; |
|
13 | 13 | |
14 | 14 | /** |
15 | 15 | * Parser Library, designed to parse payload data from various formats to php array. |
@@ -29,28 +29,28 @@ |
||
29 | 29 | * @var array Supported Formats |
30 | 30 | */ |
31 | 31 | private $supported_formats = array ( |
32 | - // XML |
|
33 | - 'application/xml' => 'xml', |
|
34 | - 'text/xml' => 'xml', |
|
35 | - // JSON |
|
36 | - 'application/json' => 'json', |
|
37 | - 'application/x-javascript' => 'json', |
|
38 | - 'text/javascript' => 'json', |
|
39 | - 'text/x-javascript' => 'json', |
|
40 | - 'text/x-json' => 'json', |
|
41 | - // BSON |
|
32 | + // XML |
|
33 | + 'application/xml' => 'xml', |
|
34 | + 'text/xml' => 'xml', |
|
35 | + // JSON |
|
36 | + 'application/json' => 'json', |
|
37 | + 'application/x-javascript' => 'json', |
|
38 | + 'text/javascript' => 'json', |
|
39 | + 'text/x-javascript' => 'json', |
|
40 | + 'text/x-json' => 'json', |
|
41 | + // BSON |
|
42 | 42 | 'application/bson' => 'bson', |
43 | - // YAML |
|
44 | - 'text/yaml' => 'yaml', |
|
45 | - 'text/x-yaml' => 'yaml', |
|
46 | - 'application/yaml' => 'yaml', |
|
47 | - 'application/x-yaml' => 'yaml', |
|
48 | - // MSGPACK |
|
43 | + // YAML |
|
44 | + 'text/yaml' => 'yaml', |
|
45 | + 'text/x-yaml' => 'yaml', |
|
46 | + 'application/yaml' => 'yaml', |
|
47 | + 'application/x-yaml' => 'yaml', |
|
48 | + // MSGPACK |
|
49 | 49 | 'application/msgpack' => 'msgpack', |
50 | 50 | 'application/x-msgpack' => 'msgpack', |
51 | - // MISC |
|
52 | - 'application/vnd.php.serialized' => 'serialize', |
|
53 | - 'application/x-www-form-urlencoded' => 'querystr' |
|
51 | + // MISC |
|
52 | + 'application/vnd.php.serialized' => 'serialize', |
|
53 | + 'application/x-www-form-urlencoded' => 'querystr' |
|
54 | 54 | ); |
55 | 55 | |
56 | 56 | /* ------------ Access Methods/Helpers ------------ */ |