You are here

interface MetadataInterface in Plug 7

Same name in this branch
  1. 7 lib/Symfony/validator/Symfony/Component/Validator/MetadataInterface.php \Symfony\Component\Validator\MetadataInterface
  2. 7 lib/Symfony/validator/Symfony/Component/Validator/Mapping/MetadataInterface.php \Symfony\Component\Validator\Mapping\MetadataInterface

A container for validation metadata.

Most importantly, the metadata stores the constraints against which an object and its properties should be validated.

Additionally, the metadata stores whether objects should be validated against their class' metadata and whether traversable objects should be traversed or not.

@since 2.5 @author Bernhard Schussek <bschussek@gmail.com>

Hierarchy

Expanded class hierarchy of MetadataInterface

All classes that implement MetadataInterface

See also

CascadingStrategy

TraversalStrategy

3 files declare their use of MetadataInterface
ExecutionContext.php in lib/Symfony/validator/Symfony/Component/Validator/Context/ExecutionContext.php
ExecutionContextInterface.php in lib/Symfony/validator/Symfony/Component/Validator/Context/ExecutionContextInterface.php
RecursiveContextualValidator.php in lib/Symfony/validator/Symfony/Component/Validator/Validator/RecursiveContextualValidator.php

File

lib/Symfony/validator/Symfony/Component/Validator/Mapping/MetadataInterface.php, line 32

Namespace

Symfony\Component\Validator\Mapping
View source
interface MetadataInterface extends LegacyMetadataInterface {

  /**
   * Returns the strategy for cascading objects.
   *
   * @return int The cascading strategy
   *
   * @see CascadingStrategy
   */
  public function getCascadingStrategy();

  /**
   * Returns the strategy for traversing traversable objects.
   *
   * @return int The traversal strategy
   *
   * @see TraversalStrategy
   */
  public function getTraversalStrategy();

  /**
   * Returns all constraints of this element.
   *
   * @return Constraint[] A list of Constraint instances
   */
  public function getConstraints();

}

Members

Namesort descending Modifiers Type Description Overrides
MetadataInterface::accept Deprecated public function Implementation of the Visitor design pattern. 1
MetadataInterface::findConstraints public function Returns all constraints for a given validation group. 1
MetadataInterface::getCascadingStrategy public function Returns the strategy for cascading objects. 1
MetadataInterface::getConstraints public function Returns all constraints of this element. 1
MetadataInterface::getTraversalStrategy public function Returns the strategy for traversing traversable objects. 1