Documentation

CastException extends FrameworkException
in package

CastException is thrown for invalid cast initialization and management.

Table of Contents

__construct()  : mixed
Tweaks the exception's constructor to assign the file/line to where it is actually raised rather than were it is instantiated.
forCopyError()  : mixed
forEnabledZlibOutputCompression()  : mixed
forFabricatorCreateFailed()  : mixed
forInvalidFile()  : mixed
forInvalidInterface()  : static
Thrown when the cast class does not extends BaseCast.
forInvalidJsonFormat()  : static
Thrown when the Json format is invalid.
forInvalidMethod()  : static
Thrown when the cast method is not `get` or `set`.
forInvalidTimestamp()  : static
Thrown when the casting timestamp is not correct timestamp.
forMissingExtension()  : mixed
forNoHandlers()  : mixed

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[, Throwable|null $previous = null ]) : mixed
Parameters
$message : string = ''
$code : int
$previous : Throwable|null = null
Return values
mixed

forCopyError()

public static forCopyError(string $path) : mixed
Parameters
$path : string
Return values
mixed

forEnabledZlibOutputCompression()

public static forEnabledZlibOutputCompression() : mixed
Return values
mixed

forFabricatorCreateFailed()

public static forFabricatorCreateFailed(string $table, string $reason) : mixed
Parameters
$table : string
$reason : string
Return values
mixed

forInvalidFile()

public static forInvalidFile(string $path) : mixed
Parameters
$path : string
Return values
mixed

forInvalidInterface()

Thrown when the cast class does not extends BaseCast.

public static forInvalidInterface(string $class) : static
Parameters
$class : string
Return values
static

forInvalidJsonFormat()

Thrown when the Json format is invalid.

public static forInvalidJsonFormat(int $error) : static
Parameters
$error : int
Return values
static

forInvalidMethod()

Thrown when the cast method is not `get` or `set`.

public static forInvalidMethod(string $method) : static
Parameters
$method : string
Return values
static

forInvalidTimestamp()

Thrown when the casting timestamp is not correct timestamp.

public static forInvalidTimestamp() : static
Return values
static

forMissingExtension()

public static forMissingExtension(string $extension) : mixed
Parameters
$extension : string
Return values
mixed

forNoHandlers()

public static forNoHandlers(string $class) : mixed
Parameters
$class : string
Return values
mixed

Search results