« Swoole\Event::set
Swoole\Event::write »

Swoole\Event::wait

(PECL swoole >= 1.9.0)

Swoole\Event::wait — Start event loop

説明

public static function Swoole\Event::wait(): void

Starts the event loop. Place this at the end of your PHP program.

戻り値

No return value.

例

例1 Swoole\Event::wait() example

<?php
Swoole\Timer::tick(1000, function () {
    echo "hello\n";
});

Swoole\Event::wait();
?>

関連キーワード:
Swoole   Event   wait   event   loop   Start   write   swoole   static   Starts   Place   program   No return   example   Timer   tick   hello
関連する関数・ページ:
swoole-event.dispatch   swoole-event.defer   swoole-event.isset   swoole-event.cycle   swoole-event.add   class.swoole-event