class Call implements CallInterface

Class Call.

Static function collection to call either global functions or object methods indirectly with checks that the requested function/method exists.

Methods

static  mixed
this( string|array|Closure $what, ...mixed $arguments)

Call a global function or class method (if exists) or callable with specified arguments.

static  mixed
func( string $function, ...mixed $arguments)

Call a global function (if exists) with specified arguments.

static  mixed
method( string|object $object, string $method, ...mixed $arguments)

Call an object method (if exists) with specified arguments.

static  mixed
staticMethod( string|object $object, string $method, ...mixed $arguments)

Call an static object method (if exists) with specified arguments.

Details

at line line 35
static mixed this( string|array|Closure $what, ...mixed $arguments)

Call a global function or class method (if exists) or callable with specified arguments.

Parameters

string|array|Closure $what A global function name or class method (if exists) or callable
...mixed $arguments Arguments to pass to the global function

Return Value

mixed

at line line 62
static mixed func( string $function, ...mixed $arguments)

Call a global function (if exists) with specified arguments.

Parameters

string $function A global function name
...mixed $arguments Arguments to pass to the global function

Return Value

mixed

at line line 76
static mixed method( string|object $object, string $method, ...mixed $arguments)

Call an object method (if exists) with specified arguments.

Parameters

string|object $object An object instance or a class name
string $method An accessible object method name
...mixed $arguments Arguments to pass to the object method

Return Value

mixed

at line line 90
static mixed staticMethod( string|object $object, string $method, ...mixed $arguments)

Call an static object method (if exists) with specified arguments.

Parameters

string|object $object An object instance or a class name
string $method An accessible object method name
...mixed $arguments Arguments to pass to the object method

Return Value

mixed