Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/php-toolkit/data-parser
simple data parser
https://github.com/php-toolkit/data-parser
Last synced: 7 days ago
JSON representation
simple data parser
- Host: GitHub
- URL: https://github.com/php-toolkit/data-parser
- Owner: php-toolkit
- License: mit
- Created: 2018-03-28T11:12:50.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2019-06-24T14:27:12.000Z (over 5 years ago)
- Last Synced: 2024-11-15T17:50:48.251Z (about 2 months ago)
- Language: PHP
- Size: 14.6 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# data parser utils
simple data parser for php
driver
- json(by `json_encode`)
- php(by `serialize`)
- swoole(by extension `swoole_serialize`)
- msgpack(by extension `msgpack`)## Install
- composer command
```bash
composer require toolkit/data-parser
```## Usage
```php
$parser = new SwooleParser();
// $parser = new JsonParser();
// $parser = new PhpParser();
// $parser = new MsgPackParser();// encode
$encoded = $parser->encode($data);// decode
$decoded = $parser->encode($encoded);
```## Unit testing
```bash
phpunit
```## License
MIT