{@see \Symfony\Component\Validator\ConstraintViolationInterface} to {@see \Ibexa\Contracts\Core\FieldType\ValidationError} adapter.
Methods¶
__construct() ¶
ConstraintViolationAdapter.php
:
35
|
|
Parameters
Name | Type | Default value | Description |
---|---|---|---|
$violation | ConstraintViolationInterface | - | - |
getTarget() ¶
ConstraintViolationAdapter.php
:
54
Returns the target element on which the error occurred.
|
|
Return values
string
getTranslatableMessage() ¶
ConstraintViolationAdapter.php
:
41
Returns a translatable Message.
|
|
Return values
setTarget() ¶
ConstraintViolationAdapter.php
:
49
Sets the target element on which the error occurred.
|
|
E.g. Property of a Field value which didn't validate against validation. Can be a property path compatible with Symfony PropertyAccess component.
Examples:
- "[StringLengthValidator][minStringLength]" => Target is "minStringLength" key under "StringLengthValidator" key (fieldtype validator configuration)
- "my_field_definition_identifier"
Parameters
Name | Type | Default value | Description |
---|---|---|---|
$target | mixed | - | - |