doctrineum/strict-string
最新稳定版本:2.1.1
Composer 安装命令:
composer require doctrineum/strict-string
包简介
Enumeration type for Doctrine - strings only
README 文档
README
About
Doctrine enum allowing strings only.
Example
$stringEnum = StrictStringEnum::getEnum('foo bar'); $stringEnum = StrictStringEnum::getEnum('12345'); // throws an exception - only string is allowed $stringEnum = StrictStringEnum::getEnum(''); // throws an exception - only string is allowed StrictStringEnum::getEnum(12); // throws an exception - only string is allowed StrictStringEnum::getEnum(false); // throws an exception - only string is allowed StrictStringEnum::getEnum(null); // throws an exception - only string is allowed StrictStringEnum::getEnum(new ObjectWithToStringMethod('foo'));
Doctrine integration
For details about new Doctrine type registration, see the parent project Doctrineum.
统计信息
- 总下载量: 494
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-05-06