Getters
in package
implements
MagicallyInvokedMethod
Interfaces, Classes, Traits and Enums
- MagicallyInvokedMethod
- MagicallyInvokedMethod is an interface for methods invoked with a little bit of magic
Table of Contents
- $prefix : string
- __construct() : mixed
- invoke() : mixed
- Invokes a method from an instance with the given parameters
- verifySignature() : bool
- Checks if the called method has the matching signature
Properties
$prefix
private
string
$prefix
Define a default prefix in method name
Methods
__construct()
public
__construct([string $prefix = 'get' ]) : mixed
Parameters
- $prefix : string = 'get'
-
Define a default prefix in method name
Tags
Return values
mixed —invoke()
Invokes a method from an instance with the given parameters
public
invoke(object $instance, string $name[, array<string|int, mixed> $arguments = [] ]) : mixed
Parameters
- $instance : object
-
Object on which the method will be invoked
- $name : string
-
Method name
- $arguments : array<string|int, mixed> = []
-
Method arguments
Tags
Return values
mixed —The return varies according to the invoked method
verifySignature()
Checks if the called method has the matching signature
public
verifySignature(string $name[, array<string|int, mixed> $arguments = [] ]) : bool
Parameters
- $name : string
-
Method name
- $arguments : array<string|int, mixed> = []
-
Method arguments
Tags
Return values
bool —The called method has the matching signature or not