ILIAS
release_7 Revision v7.30-3-g800a261c036
|
Public Member Functions | ||||
__construct (int $max_length, Data\Factory $data_factory, \ilLanguage $lng) | ||||
![]() | ||||
__construct (callable $is_ok, $error, Data\Factory $data_factory, \ilLanguage $lng) | ||||
If $error is a callable it needs to take two parameters: More... | ||||
check ($value) | ||||
Checks the provided value.Should not throw if accepts($value).
| ||||
accepts ($value) | ||||
Tells if the provided value complies.
| ||||
problemWith ($value) | ||||
Tells what the problem with the provided value is.Should return null if accepts($value).
| ||||
applyTo (Result $result) | ||||
Restricts a Result.Must do nothing with the result if $result->isError(). Must replace the result with an error according to problemWith() if !accepts($result->value()).
| ||||
![]() | ||||
withProblemBuilder (callable $builder) | ||||
Get a constraint like this one with a builder for a custom error message. More... | ||||
![]() | ||||
transform ($from) | ||||
Perform the transformation. More... | ||||
__invoke ($from) | ||||
Transformations should be callable. More... | ||||
Protected Attributes | |
$max_length | |
![]() | |
$data_factory | |
$lng | |
$is_ok | |
$error | |
Additional Inherited Members | |
![]() | |
getError () | |
Definition at line 10 of file HasMaxLength.php.
ILIAS\Refinery\String\HasMaxLength::__construct | ( | int | $max_length, |
Data\Factory | $data_factory, | ||
\ilLanguage | $lng | ||
) |
Definition at line 17 of file HasMaxLength.php.
References ILIAS\Refinery\Custom\Constraint\$data_factory, ILIAS\Refinery\Custom\Constraint\$lng, ILIAS\Refinery\String\HasMaxLength\$max_length, $txt, and ILIAS\GlobalScreen\Provider\__construct().
|
protected |
Definition at line 15 of file HasMaxLength.php.
Referenced by ILIAS\Refinery\String\HasMaxLength\__construct().