You are here

public function ValidatorInterface::startContext in Plug 7

Starts a new validation context and returns a validator for that context.

The returned validator collects all violations generated within its context. You can access these violations with the {@link ContextualValidatorInterface::getViolations()} method.

Return value

ContextualValidatorInterface The validator for the new context

1 method overrides ValidatorInterface::startContext()
RecursiveValidator::startContext in lib/Symfony/validator/Symfony/Component/Validator/Validator/RecursiveValidator.php
Starts a new validation context and returns a validator for that context.

File

lib/Symfony/validator/Symfony/Component/Validator/Validator/ValidatorInterface.php, line 87

Class

ValidatorInterface
Validates PHP values against constraints.

Namespace

Symfony\Component\Validator\Validator

Code

public function startContext();