deviantintegral / jms-serializer-uri-handler
用于序列化和反序列化PSR-7 URI对象的处理程序
1.2.0
2022-08-10 11:50 UTC
Requires
- php: ^7.4||^8.0
- guzzlehttp/psr7: ^2.0
- jms/serializer: ^3.1
Requires (Dev)
- ext-json: *
- friendsofphp/php-cs-fixer: 3.9.5
- phpunit/phpunit: 9.5.21
This package is auto-updated.
Last update: 2024-09-19 15:25:07 UTC
README
该库支持序列化和反序列化URI实例,如PSR-7定义。
使用以下方式将此处理程序添加到您的序列化程序:
AnnotationRegistry::registerLoader('class_exists'); $this->serializer = SerializerBuilder::create() ->configureHandlers( function (HandlerRegistry $registry) { $registry->registerSubscribingHandler(new UriHandler()); } )->build();