PHP 클래스 XPSPL\Routine

The routine class is used by the processor during the routine calculation for storing the idle functions and the signals which should be triggered in the next loop. This was added due to the current loop not providing a simple means for objects inside the loop determining what has happened within the routine calculation and the functionality required for the upgraded idle required more complex algorithms which would not fit well inside the entire routine loop method.
파일 보기 프로젝트 열기: prggmr/xpspl 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$_idle array Idle objects
$_is_stale boolean Routine is stale receiving no changes.
$_signals array Signals that are ready to trigger in the loop.

공개 메소드들

메소드 설명
add_idle ( SIG_Routine $routine ) : void Adds a new function to idle the engine.
add_signal ( $signal ) : array Adds a signal to trigger in the loop.
get_idle ( ) : integer Returns the object to idle the processor.
get_idles_available ( ) : integer Returns the objects created to idle the processor.
get_signals ( ) : array Returns the signals to trigger in the loop.
is_stale ( ) : boolean Returns if the routine is stale.
reset ( ) : void Resets the routine after the processor has used it.

메소드 상세

add_idle() 공개 메소드

Adds a new function to idle the engine.
public add_idle ( SIG_Routine $routine ) : void
$routine SIG_Routine
리턴 void

add_signal() 공개 메소드

Adds a signal to trigger in the loop.
public add_signal ( $signal ) : array
리턴 array

get_idle() 공개 메소드

This will only return a single object which has the greatest priority.
public get_idle ( ) : integer
리턴 integer

get_idles_available() 공개 메소드

Returns the objects created to idle the processor.
public get_idles_available ( ) : integer
리턴 integer

get_signals() 공개 메소드

Returns the signals to trigger in the loop.
public get_signals ( ) : array
리턴 array

is_stale() 공개 메소드

Returns if the routine is stale.
public is_stale ( ) : boolean
리턴 boolean

reset() 공개 메소드

Resets the routine after the processor has used it.
public reset ( ) : void
리턴 void

프로퍼티 상세

$_idle 보호되어 있는 프로퍼티

Idle objects
protected array $_idle
리턴 array

$_is_stale 보호되어 있는 프로퍼티

Routine is stale receiving no changes.
protected bool $_is_stale
리턴 boolean

$_signals 보호되어 있는 프로퍼티

Signals that are ready to trigger in the loop.
protected array $_signals
리턴 array