trait
Illuminate
/
Support
/
Traits
/
Macroable
You are viewing an older version of the documentation. For the latest, please visit master documentation.
Macroable
Properties
protected
static
$macros array
The registered string macros.
Default: []
Methods
public
static
macro ( $name , $macro ) : void
Register a custom macro.
Parameters
- $name string
- $macro object|callable
public
static
mixin ( $mixin , $replace ) : void
Mix another object into the class.
Parameters
- $mixin object
- $replace bool
public
static
hasMacro ( $name ) : bool
Checks if macro is registered.
Parameters
- $name string
public
static
flushMacros ( ) : void
Flush the existing macros.
public
static
__callStatic ( $method , $parameters ) : mixed
Dynamically handle calls to the class.
Parameters
- $method string
- $parameters array
public
__call ( $method , $parameters ) : mixed
Dynamically handle calls to the class.
Parameters
- $method string
- $parameters array