ModelException
class ModelException extends ValidationException
Used when validation fails. Contains the invalid model for easy analysis.
Properties
protected array | $fields | from ValidationException | |
protected MessageBag | $errors | from ValidationException | |
protected Model | $model |
Methods
void
__construct(Model $model)
Receives the invalid model and sets the model} and {@link errors properties.
Model
getModel()
Returns the model with invalid attributes.
MessageBag
getErrors()
Returns directly the message bag instance with the model's errors.
from
ValidationException
Details
at line 24
void
__construct(Model $model)
Receives the invalid model and sets the model} and {@link errors properties.
in
ValidationException at line 65
Model
model()
Get the mdoel with validation errors.
at line 35
Model
getModel()
Returns the model with invalid attributes.
in
ValidationException at line 83
protected
evalErrors()
Evaluate errors.
in
ValidationException at line 96
MessageBag
getErrors()
Returns directly the message bag instance with the model's errors.
in
ValidationException at line 104
getFields()
Returns invalid fields.