Copied!

InvalidArgumentType

InvalidArgumentType.php : 18

Invalid Argument Type Exception implementation.

Usage: throw new InvalidArgument( 'nodes', 'array' );

Methods

public__construct()

InvalidArgumentType.php : 28

Generates: "Argument '{$argumentName}' is invalid: expected value to be of type '{$expectedType}'[, got '{$value}']".

public __construct(string $argumentName, string $expectedType[, mixed|null $value = null ][, Exception|null $previous = null ])

Parameters

Name Type Default value Description
$argumentName string - -
$expectedType string - -
$value mixed|null null

Optionally to output the type that was received

$previous Exception|null null -