mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@328910 c90b9560-bf6c-de11-be94-00142212c4b1
104 lines
3.5 KiB
XML
104 lines
3.5 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
<phpdoc:classref xml:id="class.evidle" xmlns:phpdoc="http://php.net/ns/phpdoc" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude">
|
|
<title>The EvIdle class</title>
|
|
<titleabbrev>EvIdle</titleabbrev>
|
|
<partintro>
|
|
<!-- {{{ EvIdle intro -->
|
|
<section xml:id="evidle.intro">
|
|
&reftitle.intro;
|
|
<para>
|
|
<classname>EvIdle</classname>
|
|
watchers trigger events when no other events of the same or higher
|
|
priority are pending (
|
|
<classname>EvPrepare</classname>
|
|
,
|
|
<classname>EvCheck</classname>
|
|
and other
|
|
<classname>EvIdle</classname>
|
|
watchers do not count as receiving
|
|
<emphasis>events</emphasis>
|
|
).
|
|
</para>
|
|
<para>
|
|
Thus, as long as the process is busy handling sockets or timeouts(or even
|
|
signals) of the same or higher priority it will not be triggered. But when
|
|
the process is in idle(or only lower-priority watchers are pending), the
|
|
<classname>EvIdle</classname>
|
|
watchers are being called once per event loop iteration - until stopped,
|
|
that is, or the process receives more events and becomes busy again with
|
|
higher priority stuff.
|
|
</para>
|
|
<para>
|
|
Apart from keeping the process non-blocking(which is a useful on its own
|
|
sometimes),
|
|
<classname>EvIdle</classname>
|
|
watchers are a good place to do
|
|
<emphasis>"pseudo-background processing"</emphasis>
|
|
, or delay processing stuff to after the event loop has handled all
|
|
outstanding events.
|
|
</para>
|
|
<para>
|
|
The most noticeable effect is that as long as any
|
|
<emphasis>idle</emphasis>
|
|
watchers are active, the process will
|
|
<emphasis>not</emphasis>
|
|
block when waiting for new events.
|
|
</para>
|
|
</section>
|
|
<!-- }}} -->
|
|
<section xml:id="evidle.synopsis">
|
|
&reftitle.classsynopsis;
|
|
|
|
<!-- {{{ Synopsis -->
|
|
<classsynopsis>
|
|
<ooclass>
|
|
<classname>EvIdle</classname>
|
|
</ooclass>
|
|
<!-- {{{ Class synopsis -->
|
|
<classsynopsisinfo>
|
|
<ooclass>
|
|
<classname>EvIdle</classname>
|
|
</ooclass>
|
|
<ooclass>
|
|
<modifier>extends</modifier>
|
|
<classname>EvWatcher</classname>
|
|
</ooclass>
|
|
</classsynopsisinfo>
|
|
<!-- }}} -->
|
|
<!--<classsynopsisinfo role="comment">&Properties;</classsynopsisinfo>-->
|
|
<classsynopsisinfo role="comment">&InheritedProperties;</classsynopsisinfo>
|
|
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('evwatcher.synopsis')/descendant::db:fieldsynopsis)" />
|
|
<classsynopsisinfo role="comment">&Methods;</classsynopsisinfo>
|
|
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.evidle')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[1])" />
|
|
<classsynopsisinfo role="comment">&InheritedMethods;</classsynopsisinfo>
|
|
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.evwatcher')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[1])" />
|
|
</classsynopsis>
|
|
<!-- }}} -->
|
|
</section>
|
|
<!-- }}} -->
|
|
</partintro>
|
|
|
|
&reference.ev.entities.evidle;
|
|
|
|
</phpdoc:classref>
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|