class RequirementsException extends RuntimeException (View source)

Defines an exception thrown when a migration does not meet the requirements.

Properties

protected array $requirements

The missing requirements.

Methods

__construct(string $message = "", array $requirements = [], int $code = 0, Exception $previous = NULL)

Constructs a new RequirementsException instance.

array
getRequirements()

Get an array of requirements.

string
getRequirementsString()

Get the requirements as a string.

Details

__construct(string $message = "", array $requirements = [], int $code = 0, Exception $previous = NULL)

Constructs a new RequirementsException instance.

Parameters

string $message

(optional) The Exception message to throw.

array $requirements

(optional) The missing requirements.

int $code

(optional) The Exception code.

Exception $previous

(optional) The previous exception used for the exception chaining.

array getRequirements()

Get an array of requirements.

Return Value

array

The requirements.

string getRequirementsString()

Get the requirements as a string.

Return Value

string

A formatted requirements string.