class ValidationException extends HttpException (View source)

Properties

protected string $status

Define the status code has message

from  HttpException
protected array $error_bags

Define the errors bags

from  HttpException

Methods

__construct(string $message, array $errors = [], string $status = 'VALIDATION_ERROR')

ValidationException constructor

string
getStatus()

Get the define user error code

int
getStatusCode()

Get the status code

array
getErrorBags()

Get the errors bags

setErrorBags(array $errors)

Set the errors bags

array
getErrors()

Get the errors

Details

__construct(string $message, array $errors = [], string $status = 'VALIDATION_ERROR')

ValidationException constructor

Parameters

string $message
array $errors
string $status

string getStatus()

Get the define user error code

Return Value

string

int getStatusCode()

Get the status code

Return Value

int

array getErrorBags()

Get the errors bags

Return Value

array

setErrorBags(array $errors)

Set the errors bags

Parameters

array $errors

array getErrors()

Get the errors

Return Value

array