Drupal investigation

Issn.php 1.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien@symfony.com>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Component\Validator\Constraints;
  11. use Symfony\Component\Validator\Constraint;
  12. /**
  13. * @Annotation
  14. * @Target({"PROPERTY", "METHOD", "ANNOTATION"})
  15. *
  16. * @author Antonio J. García Lagar <aj@garcialagar.es>
  17. * @author Bernhard Schussek <bschussek@gmail.com>
  18. */
  19. class Issn extends Constraint
  20. {
  21. const TOO_SHORT_ERROR = '6a20dd3d-f463-4460-8e7b-18a1b98abbfb';
  22. const TOO_LONG_ERROR = '37cef893-5871-464e-8b12-7fb79324833c';
  23. const MISSING_HYPHEN_ERROR = '2983286f-8134-4693-957a-1ec4ef887b15';
  24. const INVALID_CHARACTERS_ERROR = 'a663d266-37c2-4ece-a914-ae891940c588';
  25. const INVALID_CASE_ERROR = '7b6dd393-7523-4a6c-b84d-72b91bba5e1a';
  26. const CHECKSUM_FAILED_ERROR = 'b0f92dbc-667c-48de-b526-ad9586d43e85';
  27. protected static $errorNames = array(
  28. self::TOO_SHORT_ERROR => 'TOO_SHORT_ERROR',
  29. self::TOO_LONG_ERROR => 'TOO_LONG_ERROR',
  30. self::MISSING_HYPHEN_ERROR => 'MISSING_HYPHEN_ERROR',
  31. self::INVALID_CHARACTERS_ERROR => 'INVALID_CHARACTERS_ERROR',
  32. self::INVALID_CASE_ERROR => 'INVALID_CASE_ERROR',
  33. self::CHECKSUM_FAILED_ERROR => 'CHECKSUM_FAILED_ERROR',
  34. );
  35. public $message = 'This value is not a valid ISSN.';
  36. public $caseSensitive = false;
  37. public $requireHyphen = false;
  38. }