PHP 클래스 izzum\command\Closure

This allows clients of a Command to inject logic by means of an anonymous function. This provides the flexibility to use custom logic in a command without subclassing a command, while still allowing the use of the command library. eg: $command = new Closure(function() {echo "hello world";}); $command->execute();//echoes 'hello world'
저자: Rolf Vreijdenberger
상속: extends Command
파일 보기 프로젝트 열기: rolfvreijdenberger/izzum-statemachine 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( Closure $closure, array $arguments = [] )

보호된 메소드들

메소드 설명
_execute ( )

메소드 상세

__construct() 공개 메소드

public __construct ( Closure $closure, array $arguments = [] )
$closure Closure
$arguments array an optional array of arguments to pass to the closure

_execute() 보호된 메소드

protected _execute ( )