You are here

final class Validation in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/validator/Validation.php \Symfony\Component\Validator\Validation

Entry point for the Validator component.

@author Bernhard Schussek <bschussek@gmail.com>

Hierarchy

Expanded class hierarchy of Validation

44 files declare their use of Validation
AbstractConstraintValidatorTest.php in vendor/symfony/validator/Tests/Constraints/AbstractConstraintValidatorTest.php
AllValidatorTest.php in vendor/symfony/validator/Tests/Constraints/AllValidatorTest.php
BlankValidatorTest.php in vendor/symfony/validator/Tests/Constraints/BlankValidatorTest.php
CallbackValidatorTest.php in vendor/symfony/validator/Tests/Constraints/CallbackValidatorTest.php
CardSchemeValidatorTest.php in vendor/symfony/validator/Tests/Constraints/CardSchemeValidatorTest.php

... See full list

File

vendor/symfony/validator/Validation.php, line 19

Namespace

Symfony\Component\Validator
View source
final class Validation {

  /**
   * The Validator API provided by Symfony 2.4 and older.
   *
   * @deprecated use API_VERSION_2_5_BC instead.
   */
  const API_VERSION_2_4 = 1;

  /**
   * The Validator API provided by Symfony 2.5 and newer.
   */
  const API_VERSION_2_5 = 2;

  /**
   * The Validator API provided by Symfony 2.5 and newer with a backwards
   * compatibility layer for 2.4 and older.
   */
  const API_VERSION_2_5_BC = 3;

  /**
   * Creates a new validator.
   *
   * If you want to configure the validator, use
   * {@link createValidatorBuilder()} instead.
   *
   * @return ValidatorInterface The new validator.
   */
  public static function createValidator() {
    return self::createValidatorBuilder()
      ->getValidator();
  }

  /**
   * Creates a configurable builder for validator objects.
   *
   * @return ValidatorBuilderInterface The new builder.
   */
  public static function createValidatorBuilder() {
    return new ValidatorBuilder();
  }

  /**
   * This class cannot be instantiated.
   */
  private function __construct() {
  }

}

Members

Namesort descending Modifiers Type Description Overrides
Validation::API_VERSION_2_4 Deprecated constant The Validator API provided by Symfony 2.4 and older.
Validation::API_VERSION_2_5 constant The Validator API provided by Symfony 2.5 and newer.
Validation::API_VERSION_2_5_BC constant The Validator API provided by Symfony 2.5 and newer with a backwards compatibility layer for 2.4 and older.
Validation::createValidator public static function Creates a new validator.
Validation::createValidatorBuilder public static function Creates a configurable builder for validator objects.
Validation::__construct private function This class cannot be instantiated.