| 1 | <?php |
||
| 12 | class OrganizationId implements IdInterface |
||
| 13 | { |
||
| 14 | use BasicIdTrait; |
||
| 15 | |||
| 16 | /** |
||
| 17 | * Regular expression describing id structure |
||
| 18 | */ |
||
| 19 | private const PATTERN = '/^(?:00)?(\d{2}[2-9]\d{3})[-]?(\d{3})(\d)$/'; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Create organizational identity number |
||
| 23 | * |
||
| 24 | * @throws UnableToCreateIdException On failure to create id |
||
| 25 | */ |
||
| 26 | public function __construct(string $number) |
||
| 32 | |||
| 33 | public function getLegalForm(): string |
||
| 37 | } |
||
| 38 |