PHP Trait Nestable\MacrosTrait

Mostra file Open project: atayahmet/laravel-nestable

Protected Properties

Property Type Description
$macros

Public Methods

Method Description
hasMacro ( string $name ) : boolean Macro checker.
macro ( string $name, Closure $macro ) New macro.
removeMacro ( string $name ) Remove a macro.
runMacro ( string $name, mixed $args ) : mixed Run the macros.

Method Details

hasMacro() public method

Macro checker.
public hasMacro ( string $name ) : boolean
$name string
return boolean

macro() public method

New macro.
public macro ( string $name, Closure $macro )
$name string
$macro Closure

removeMacro() public method

Remove a macro.
public removeMacro ( string $name )
$name string Macro name

runMacro() public method

Run the macros.
public runMacro ( string $name, mixed $args ) : mixed
$name string
$args mixed
return mixed

Property Details

$macros protected_oe property

protected $macros