eventInterface
in
Table of Contents
- EV_READ = -1
- SEND_FAILED = -1
- delay() : int|bool
- Delay the execution of a callback.
- deleteAllTimer() : void
- Delete all timer.
- deleteTimer() : bool
- Delete a timer.
- getTimerCount() : int
- offReadable() : void
- Cancel a callback of stream readable.
- offSignal() : void
- Cancel a callback of signal.
- offWritable() : string|array<string|int, mixed>|object|null
- Cancel a callback of stream writable.
- onReadable() : void
- Execute a callback when a stream resource becomes readable or is closed for reading.
- onSignal() : void
- Execute a callback when a signal is received.
- onWritable() : void
- Execute a callback when a stream resource becomes writable or is closed for writing.
- repeat() : int|bool
- Repeatedly execute a callback.
- run() : void
- Run the event loop.
- stop() : void
- Stop event loop.
Constants
EV_READ
public
mixed
EV_READ
= -1
SEND_FAILED
public
mixed
SEND_FAILED
= -1
Methods
delay()
Delay the execution of a callback.
public
delay(float $delay, $func, $args) : int|bool
Parameters
Return values
int|bool —deleteAllTimer()
Delete all timer.
public
deleteAllTimer() : void
Return values
void —deleteTimer()
Delete a timer.
public
deleteTimer( $timer_id) : bool
Parameters
Return values
bool —getTimerCount()
public
getTimerCount() : int
Return values
int —offReadable()
Cancel a callback of stream readable.
public
offReadable( $stream) : void
Parameters
Return values
void —offSignal()
Cancel a callback of signal.
public
offSignal( $signal) : void
Parameters
Return values
void —offWritable()
Cancel a callback of stream writable.
public
offWritable( $stream) : string|array<string|int, mixed>|object|null
Parameters
Return values
string|array<string|int, mixed>|object|null —onReadable()
Execute a callback when a stream resource becomes readable or is closed for reading.
public
onReadable( $stream, $func) : void
Parameters
Return values
void —onSignal()
Execute a callback when a signal is received.
public
onSignal( $signal, $func) : void
Parameters
Return values
void —onWritable()
Execute a callback when a stream resource becomes writable or is closed for writing.
public
onWritable( $stream, $func) : void
Parameters
Return values
void —repeat()
Repeatedly execute a callback.
public
repeat(float $interval, $func, $args) : int|bool
Parameters
Return values
int|bool —run()
Run the event loop.
public
run() : void
Return values
void —stop()
Stop event loop.
public
stop() : void