mirror of
https://github.com/Respect/Validation.git
synced 2024-06-06 07:42:15 +02:00
aa7d84c3ea
This commit also creates `AbstractLocaleWrapper` to help creating locale-based rules.
34 lines
726 B
PHP
34 lines
726 B
PHP
<?php
|
|
|
|
/*
|
|
* This file is part of Respect/Validation.
|
|
*
|
|
* (c) Alexandre Gomes Gaigalas <alexandre@gaigalas.net>
|
|
*
|
|
* For the full copyright and license information, please view the "LICENSE.md"
|
|
* file that was distributed with this source code.
|
|
*/
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Respect\Validation\Rules;
|
|
|
|
/**
|
|
* Validates country subdivision codes according to ISO 3166-2.
|
|
*
|
|
* @see http://en.wikipedia.org/wiki/ISO_3166-2
|
|
* @see http://www.geonames.org/countries/
|
|
*
|
|
* @author Henrique Moody <henriquemoody@gmail.com>
|
|
*/
|
|
final class SubdivisionCode extends AbstractLocaleWrapper
|
|
{
|
|
/**
|
|
* {@inheritdoc}
|
|
*/
|
|
protected function getSuffix(): string
|
|
{
|
|
return 'SubdivisionCode';
|
|
}
|
|
}
|