承接 scato/serializer 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

scato/serializer

最新稳定版本:v0.3.0

Composer 安装命令:

composer require scato/serializer

包简介

README 文档

README

Latest Version on Packagist Software License Build Status

An alternative serializer that minimizes configuration, and is focused on DTOs instead of Entities.

Install

Via Composer

$ composer require scato/serializer

Usage

$serializer = SerializerFacade::create();
$string = $serializer->serialize(..., 'json');

Read the docs for more examples on how to use the serializer, or jump to Advanced Usage to learn about custom type handling and custom factories.

Change log

Please see CHANGELOG for more information on what has changed recently.

Testing

$ composer test

Contributing

Please see CONTRIBUTING for details.

Known issues

Composite types are not supported. If your type reads array|Foo[] or string|null, you're out of luck.

Deserialization does not support polymorphism. If a type says Foo, an object will never be deserialized as a subclass of Foo. The reason for this is that DocBlocks have no way to define discriminators. (Maybe we could use the @uses tag to point to a property with a default value, so the property/value-pair can be used as a discriminator.)

No caching is performed, which makes deserialization relatively slow.

There is a problem with the phpdocumentor/reflection-common component, so you have to add it to your own composer.json:

  "require": {
    "phpdocumentor/reflection-common": "^1.0@dev"
  }

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 14
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-07-19