ValidationException
extends DomainException
in package
Basic exception for domain errors
Table of Contents
Properties
- $context : array<string|int, mixed>
- $errorCode : string
- $httpStatusCode : int
Methods
- __construct() : mixed
- invalidCsrf() : self
- Thrown when invalid csrf provided
- invalidInput() : self
- missingCsrf() : self
- Thrown when no csrf found
Properties
$context read-only
public
array<string|int, mixed>
$context
= []
$errorCode read-only
public
string
$errorCode
$httpStatusCode read-only
public
int
$httpStatusCode
= 400
Methods
__construct()
public
__construct(string $message, string $errorCode[, int $httpStatusCode = 400 ][, array<string|int, mixed> $context = [] ][, Throwable|null $previous = null ]) : mixed
Parameters
- $message : string
- $errorCode : string
- $httpStatusCode : int = 400
- $context : array<string|int, mixed> = []
- $previous : Throwable|null = null
invalidCsrf()
Thrown when invalid csrf provided
public
static invalidCsrf([Throwable|null $previous = null ]) : self
Parameters
- $previous : Throwable|null = null
Return values
selfinvalidInput()
public
static invalidInput(array<string, array<int, string>> $errors[, Throwable|null $previous = null ]) : self
Parameters
- $errors : array<string, array<int, string>>
- $previous : Throwable|null = null
Return values
selfmissingCsrf()
Thrown when no csrf found
public
static missingCsrf([Throwable|null $previous = null ]) : self
Parameters
- $previous : Throwable|null = null