Mercurial > hg > isophonics-drupal-site
comparison vendor/symfony/validator/Constraints/Issn.php @ 0:4c8ae668cc8c
Initial import (non-working)
author | Chris Cannam |
---|---|
date | Wed, 29 Nov 2017 16:09:58 +0000 |
parents | |
children | 129ea1e6d783 |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:4c8ae668cc8c |
---|---|
1 <?php | |
2 | |
3 /* | |
4 * This file is part of the Symfony package. | |
5 * | |
6 * (c) Fabien Potencier <fabien@symfony.com> | |
7 * | |
8 * For the full copyright and license information, please view the LICENSE | |
9 * file that was distributed with this source code. | |
10 */ | |
11 | |
12 namespace Symfony\Component\Validator\Constraints; | |
13 | |
14 use Symfony\Component\Validator\Constraint; | |
15 | |
16 /** | |
17 * @Annotation | |
18 * @Target({"PROPERTY", "METHOD", "ANNOTATION"}) | |
19 * | |
20 * @author Antonio J. GarcĂa Lagar <aj@garcialagar.es> | |
21 * @author Bernhard Schussek <bschussek@gmail.com> | |
22 */ | |
23 class Issn extends Constraint | |
24 { | |
25 const TOO_SHORT_ERROR = '6a20dd3d-f463-4460-8e7b-18a1b98abbfb'; | |
26 const TOO_LONG_ERROR = '37cef893-5871-464e-8b12-7fb79324833c'; | |
27 const MISSING_HYPHEN_ERROR = '2983286f-8134-4693-957a-1ec4ef887b15'; | |
28 const INVALID_CHARACTERS_ERROR = 'a663d266-37c2-4ece-a914-ae891940c588'; | |
29 const INVALID_CASE_ERROR = '7b6dd393-7523-4a6c-b84d-72b91bba5e1a'; | |
30 const CHECKSUM_FAILED_ERROR = 'b0f92dbc-667c-48de-b526-ad9586d43e85'; | |
31 | |
32 protected static $errorNames = array( | |
33 self::TOO_SHORT_ERROR => 'TOO_SHORT_ERROR', | |
34 self::TOO_LONG_ERROR => 'TOO_LONG_ERROR', | |
35 self::MISSING_HYPHEN_ERROR => 'MISSING_HYPHEN_ERROR', | |
36 self::INVALID_CHARACTERS_ERROR => 'INVALID_CHARACTERS_ERROR', | |
37 self::INVALID_CASE_ERROR => 'INVALID_CASE_ERROR', | |
38 self::CHECKSUM_FAILED_ERROR => 'CHECKSUM_FAILED_ERROR', | |
39 ); | |
40 | |
41 public $message = 'This value is not a valid ISSN.'; | |
42 public $caseSensitive = false; | |
43 public $requireHyphen = false; | |
44 } |