(PECL swoole >= 1.9.0)
Swoole\Event::defer — Execute a function at the start of the next event loop
Schedules a function to run at the start of the next event loop iteration.
callback_function
Callback function to execute (no parameters allowed; use use for closure variables).
No return value.
示例 #1 Swoole\Event::defer() example
<?php
Swoole\Event::defer(function(){
echo "After EventLoop\n";
});
?>