eio_nreqs

(PECL eio >= 0.0.1dev)

eio_nreqsReturns number of requests to be processed

说明

eio_nreqs ( void ) : int

eio_nreqs() could be called in a custom loop calling eio_poll().

参数

此函数没有参数。

返回值

eio_nreqs() returns number of requests to be processed.

范例

Example #1 eio_nreqs() example

<?php
function res_cb($data$result) {
    
var_dump($data);
    
var_dump($result);
}

eio_nop(EIO_PRI_DEFAULT"res_cb""1");
eio_nop(EIO_PRI_DEFAULT"res_cb""2");
eio_nop(EIO_PRI_DEFAULT"res_cb""3");

while (
eio_nreqs()) {
    
eio_poll();
}
?>

以上例程的输出类似于:

string(1) "1"
int(0)
string(1) "3"
int(0)
string(1) "2"
int(0)

参见

  • eio_poll
  • eio_nready
相关文章
php eio 函数 polls libeio until all requests proceededphp eio 函数 returns number of finished but unhandled requestsphp eio 函数 returns number of not yet handled requestsphp eio 函数 returns number of requests to be processedphp eio 函数 returns number of threads currently in usephp eio 函数 can be to be called whenever there are pending requests that need finishingphp eio 函数 set maximum number of requests processed in a pollphp informix 函数 returns the number of columns in the queryphp mcve 函数 returns array of strings which represents the keys that can be used for response parameters on this transactionphp maxdb 函数 returns the number of parameter for the given statementphp postgresql 函数 returns the type id oid for the corresponding field numberphp paradox 函数 returns number of records in a databasephp svn 函数 creates and returns a stream that will be used to replacephp svn 函数 returns the number of the youngest revision in the filesystemphp tidy 函数 returns the number of tidy accessibility warnings encountered for specified documentphp tidy 函数 returns the number of tidy configuration errors encountered for specified documentphp tidy 函数 returns the number of tidy errors encountered for specified documentphp yaz 函数 returns number of hits for last searchphp solrquery returns the maximum number of constraint counts that should be returned for the facet fieldsphp solrquery returns the maximum number of query terms that will be included in any generated query
关注编程学问公众号