目录

PHP mysqli poll() 函数

❮ PHP MySQLi 参考


定义和用法

poll() / mysqli_poll() 函数用于轮询连接。


语法

面向对象风格:

$mysqli -> poll( read, error, reject, seconds, microseconds)

程序风格:

mysqli_poll( read, error, reject, seconds, microseconds)

参数值

Parameter Description
read Required. Specifies a list of connections to check for outstanding results that can be read
error Required. Specifies a list of connections on which an error occurred, like query failure or lost connection
reject Required. Specifies a list of connections rejected because no asynchronous query has been run on for which the function could poll results
seconds Required. Specifies the maximum number of seconds to wait
microseconds Optional. Specifies the maximum number of microseconds to wait. Default is 0

技术细节

返回值: 成功时的就绪连接数。失败时为 FALSE
PHP 版本: 5.3+

❮ PHP MySQLi 参考