PageNotFoundException
extends OutOfBoundsException
in package
implements
ExceptionInterface, HTTPExceptionInterface
uses
DebugTraceableTrait
Table of Contents
Interfaces
- ExceptionInterface
- Provides a domain-level interface for broad capture of all framework-related exceptions.
- HTTPExceptionInterface
- Interface for Exceptions that has exception code as HTTP status code.
Properties
- $code : int
- HTTP status code
Methods
- __construct() : mixed
- Tweaks the exception's constructor to assign the file/line to where it is actually raised rather than were it is instantiated.
- forControllerNotFound() : static
- forEmptyController() : static
- forLocaleNotSupported() : static
- forMethodNotFound() : static
- forPageNotFound() : static
- lang() : string
- Get translated system message
Properties
$code
HTTP status code
protected
int
$code
= 404
Methods
__construct()
Tweaks the exception's constructor to assign the file/line to where it is actually raised rather than were it is instantiated.
public
final __construct([string $message = '' ][, int $code = 0 ][, Throwable|null $previous = null ]) : mixed
Parameters
- $message : string = ''
- $code : int = 0
- $previous : Throwable|null = null
forControllerNotFound()
public
static forControllerNotFound(string $controller, string $method) : static
Parameters
- $controller : string
- $method : string
Return values
staticforEmptyController()
public
static forEmptyController() : static
Return values
staticforLocaleNotSupported()
public
static forLocaleNotSupported(string $locale) : static
Parameters
- $locale : string
Return values
staticforMethodNotFound()
public
static forMethodNotFound(string $method) : static
Parameters
- $method : string
Return values
staticforPageNotFound()
public
static forPageNotFound([string|null $message = null ]) : static
Parameters
- $message : string|null = null
Return values
staticlang()
Get translated system message
private
static lang(string $line[, array<string|int, mixed> $args = [] ]) : string
Use a non-shared Language instance in the Services.
If a shared instance is created, the Language will
have the current locale, so even if users call
$this->request->setLocale()
in the controller afterwards,
the Language locale will not be changed.
Parameters
- $line : string
- $args : array<string|int, mixed> = []