Swoole\Runtime::enableCoroutine
(No version information available, might only be in Git)
Swoole\Runtime::enableCoroutine — Enable coroutine for specified functions
Description
This method enables coroutine support for specified PHP functions based on the given flags. It should be called once at the beginning of the application.
Parameters
flagsBitmask of flags specifying which functions to hook. Can be combined using | operator. Available flags:
SWOOLE_HOOK_TCP,SWOOLE_HOOK_UDP,SWOOLE_HOOK_UNIX,SWOOLE_HOOK_UDG,SWOOLE_HOOK_SSL,SWOOLE_HOOK_TLS,SWOOLE_HOOK_SLEEP,SWOOLE_HOOK_FILE,SWOOLE_HOOK_STREAM_FUNCTION,SWOOLE_HOOK_BLOCKING_FUNCTION,SWOOLE_HOOK_PROC,SWOOLE_HOOK_CURL,SWOOLE_HOOK_NATIVE_CURL,SWOOLE_HOOK_SOCKETS,SWOOLE_HOOK_STDIO,SWOOLE_HOOK_PDO_PGSQL,SWOOLE_HOOK_PDO_ODBC,SWOOLE_HOOK_PDO_ORACLE,SWOOLE_HOOK_PDO_SQLITE, orSWOOLE_HOOK_ALLfor all flags.
Return Values
No value is returned.