Validator.php 723 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. namespace Gedmo\ReferenceIntegrity\Mapping;
  3. /**
  4. * This class is used to validate mapping information
  5. *
  6. * @author Evert Harmeling <evert.harmeling@freshheads.com>
  7. * @license MIT License (http://www.opensource.org/licenses/mit-license.php)
  8. */
  9. class Validator
  10. {
  11. const NULLIFY = 'nullify';
  12. const RESTRICT = 'restrict';
  13. /**
  14. * List of actions which are valid as integrity check
  15. *
  16. * @var array
  17. */
  18. private $integrityActions = array(
  19. self::RESTRICT,
  20. self::NULLIFY
  21. );
  22. /**
  23. * Returns a list of available integrity actions
  24. *
  25. * @return array
  26. */
  27. public function getIntegrityActions()
  28. {
  29. return $this->integrityActions;
  30. }
  31. }