Symfony\Component\Validator\ExecutionContextInterface::addViolation
Adds a violation at the current node of the validation graph.
Signature
public function addViolation(string
$message,
[array
$params = null,
[mixed
$invalidValue = null,
[integer|null
$pluralization = null,
[integer|null
$code = null]]]] )
Parameters
$message
—
string
- The error message.
$params
—
array
- The parameters substituted in the error message.
$invalidValue
—
mixed
- The invalid, validated value.
$pluralization
—
object
- The number to use to pluralize of the message.
$code
—
object
- The violation code.