Overview
KB
Technical FAQ
PHP Manual
CSS2 Manual
HTML Manual
JS Guide
JS Reference
PhpDock Manual
Nu-Coder Manual
PhpExpress Manual
PHP Joomla
Development
Learn PHP
 
<Swoole\Runtime::getHookFlagsSwoole\Serialize>
^Swoole\RuntimeLast updated: Mon, 26 Oct 2026

Swoole\Runtime::setHookFlags

(No version information available, might only be in Git)

Swoole\Runtime::setHookFlags — Set hook flags for coroutine

Description

public static function Swoole\Runtime::setHookFlags(int $flags): bool

Sets the hook flags for coroutine support. This dynamically changes the hook flags at runtime.

Parameters

flags

Bitmask of flags specifying which functions to hook. Same flags as enableCoroutine.

Return Values

Returns true on success or false on failure.


<Swoole\Runtime::getHookFlagsSwoole\Serialize>
^Swoole\RuntimeLast updated: Mon, 26 Oct 2026