Interface

Symfony\Component\Validator\ConstraintValidatorInterface

interface ConstraintValidatorInterface

Methods

initialize(ExecutionContext $context)

Initializes the constraint validator.

Boolean isValid(mixed $value, Constraint $constraint)

Checks if the passed value is valid.

string getMessageTemplate()

array getMessageParameters()

Details

at line 24
public initialize(ExecutionContext $context)

Initializes the constraint validator.

Parameters

ExecutionContext $context The current validation context

at line 36
public Boolean isValid(mixed $value, Constraint $constraint)

Checks if the passed value is valid.

Parameters

mixed $value The value that should be validated
Constraint $constraint The constrain for the validation

Return Value

Boolean Whether or not the value is valid

at line 43
public string getMessageTemplate()

Return Value

string

at line 50
public array getMessageParameters()

Return Value

array