jleo / popo-hyperf
Installs: 0
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/jleo/popo-hyperf
Requires (Dev)
- hyperf/framework: ^3.1
- hyperf/http-server: ^3.1
- hyperf/stringable: ^3.1
- hyperf/validation: ^3.1
This package is auto-updated.
Last update: 2025-10-22 12:19:06 UTC
README
将入参数据绑定到对象中,支持一维数据,也支持多维数据,参考java的pojo而来
此包适用hyperf框架
thinkphp 框架可参考下边的 https://github.com/afubao/popo-thinkphp
使用
需要再config中启用popo中间件 PoPoMiddleware::class
定义相对应的数据,待完善
class TestParam extends \Leo\Popo\Popo { private int $intValue; private string $stringValue; private array $arrayValue; private UserParam $objValue1; #[ObjArray(UserParam::class)] private array $objValue2; }