PHP 클래스 Resque\Event

저자: Chris Boulton ([email protected])
파일 보기 프로젝트 열기: mjphaynes/php-resque 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$events containing all registered callbacks, indexed by event name

공개 메소드들

메소드 설명
clear ( ) Clear all registered listeners.
eventName ( integer $event ) : string | false Returns the name of the given event from constant
fire ( string $event, mixed $data = null ) : true Raise a given event with the supplied data.
forget ( string $event, mixed $callback ) : true Stop a given callback from listening on a specific event.
listen ( string $event, mixed $callback ) : true Listen in on a given event to have a specified callback fired.

메소드 상세

clear() 공개 정적인 메소드

Clear all registered listeners.
public static clear ( )

eventName() 공개 정적인 메소드

Returns the name of the given event from constant
public static eventName ( integer $event ) : string | false
$event integer Event constant
리턴 string | false

fire() 공개 정적인 메소드

Raise a given event with the supplied data.
public static fire ( string $event, mixed $data = null ) : true
$event string Name of event to be raised
$data mixed Data that should be passed to each callback (optional)
리턴 true

forget() 공개 정적인 메소드

Stop a given callback from listening on a specific event.
public static forget ( string $event, mixed $callback ) : true
$event string Name of event
$callback mixed The callback as defined when listen() was called
리턴 true

listen() 공개 정적인 메소드

Listen in on a given event to have a specified callback fired.
public static listen ( string $event, mixed $callback ) : true
$event string Name of event to listen on.
$callback mixed Any callback callable by call_user_func_array
리턴 true

프로퍼티 상세

$events 보호되어 있는 정적으로 프로퍼티

containing all registered callbacks, indexed by event name
protected static $events