reliv/pipe-rat
Composer 安装命令:
composer require reliv/pipe-rat
包简介
Create REST APIs with just a few lines of config. This PSR7 compliant PHP library uses Zend\Stragility Middleware at its core.
README 文档
README
Create REST APIs with just a few lines of config. This PSR7 compliant PHP library that uses Zend\Stragility Middleware at its core.
@todo Docs
-
There is a name collision happening when pre and|or post service options have the same name I.E.: responseHeaders in this example, looses the postServiceOptions values in the 'findById'
'xxx' => [ 'controllerServiceName' => 'Reliv\PipeRat\Middleware\ResourceController\DoctrineResourceController', 'controllerServiceOptions' => [ 'entity' => null, ], 'methods' => [ 'findById' => [ 'postServiceNames' => [ 'extractor' => 'Reliv\PipeRat\Middleware\Extractor\PropertyGetterExtractor', 'responseHeaders' => 'Reliv\PipeRat\Middleware\Header\AddResponseHeaders', ], 'postServiceOptions' => [ 'responseHeaders' => [ 'headers' => [ 'My' => 'header' ] ] ], ], ], 'preServiceOptions' => [ ], 'preServicePriority' => [ // 'JsonRequestFormat' => 1000, ], 'postServiceNames' => [ 'responseHeaders' => 'Reliv\PipeRat\Middleware\Header\AddResponseHeaders', 'JsonResponseFormat' => 'Reliv\PipeRat\Middleware\ResponseFormat\JsonResponseFormat', 'XmlResponseFormat' => 'Reliv\PipeRat\Middleware\ResponseFormat\XmlResponseFormat', 'DefaultResponseFormat' => 'Reliv\PipeRat\Middleware\ResponseFormat\JsonResponseFormat', ], 'postServiceOptions' => [ 'DefaultResponseFormat' => [ 'accepts' => [ '*/*' ], ], ], ]
统计信息
- 总下载量: 1.97k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 3
- 点击次数: 1
- 依赖项目数: 4
- 推荐数: 0
其他信息
- 授权协议: BSD-3-Clause
- 更新时间: 2016-04-27