Свойство | Тип | Описание | |
---|---|---|---|
$errors | string[] | Contains an array of errors that occurred during validation | |
$failedRules | Fuel\Validation\RuleInterface[] | Contains the rule that caused a given field to fail | |
$result | boolean | Boolean flag to indicate overall failure or success | |
$validated | string[] | Contains a list of fields that passed validation |
Метод | Описание | |
---|---|---|
getError ( string $field ) : string | ||
getErrors ( ) : string[] | ||
getFailedRules ( ) : Fuel\Validation\RuleInterface[] | Returns a list of rules that caused fields to fail, indexed by the field name. | |
getValidated ( ) : string[] | ||
isValid ( ) : boolean | ||
merge ( Fuel\Validation\ResultInterface $resultInterface, $fieldPrefix = '' ) | ||
setError ( string $field, string $message, string $rule ) | Sets the error message for the given field | |
setResult ( boolean $isValid ) | ||
setValidated ( string $field ) |
public getFailedRules ( ) : Fuel\Validation\RuleInterface[] | ||
Результат | Fuel\Validation\RuleInterface[] |
public merge ( Fuel\Validation\ResultInterface $resultInterface, $fieldPrefix = '' ) | ||
$resultInterface | Fuel\Validation\ResultInterface |
protected string[] $errors | ||
Результат | string[] |
protected RuleInterface[],Fuel\Validation $failedRules | ||
Результат | Fuel\Validation\RuleInterface[] |
protected bool $result | ||
Результат | boolean |