<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <title>Set the watermarks for read and write events</title> </head> <body><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.event-buffer-timeout-set.html">event_buffer_timeout_set</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.event-buffer-write.html">event_buffer_write</a></div> <div class="up"><a href="ref.libevent.html">Libevent Functions</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div><hr /><div id="function.event-buffer-watermark-set" class="refentry"> <div class="refnamediv"> <h1 class="refname">event_buffer_watermark_set</h1> <p class="verinfo">(PECL libevent >= 0.0.1)</p><p class="refpurpose"><span class="refname">event_buffer_watermark_set</span> — <span class="dc-title">Set the watermarks for read and write events</span></p> </div> <div class="refsect1 description" id="refsect1-function.event-buffer-watermark-set-description"> <h3 class="title">Description</h3> <div class="methodsynopsis dc-description"> <span class="type"><span class="type void">void</span></span> <span class="methodname"><strong>event_buffer_watermark_set</strong></span> ( <span class="methodparam"><span class="type">resource</span> <code class="parameter">$bevent</code></span> , <span class="methodparam"><span class="type">int</span> <code class="parameter">$events</code></span> , <span class="methodparam"><span class="type">int</span> <code class="parameter">$lowmark</code></span> , <span class="methodparam"><span class="type">int</span> <code class="parameter">$highmark</code></span> )</div> <p class="para rdfs-comment"> Sets the watermarks for read and write events. Libevent does not invoke read callback unless there is at least <em><code class="parameter">lowmark</code></em> bytes in the input buffer; if the read buffer is beyond the <em><code class="parameter">highmark</code></em>, reading is stopped. On output, the write callback is invoked whenever the buffered data falls below the <em><code class="parameter">lowmark</code></em>. </p> </div> <div class="refsect1 parameters" id="refsect1-function.event-buffer-watermark-set-parameters"> <h3 class="title">Parameters</h3> <p class="para"> <dl> <dt> <span class="term"><em><code class="parameter">bevent</code></em></span> <dd> <p class="para"> Valid buffered event resource. </p> </dd> </dt> <dt> <span class="term"><em><code class="parameter">events</code></em></span> <dd> <p class="para"> Any combination of <strong><code>EV_READ</code></strong> and <strong><code>EV_WRITE</code></strong>. </p> </dd> </dt> <dt> <span class="term"><em><code class="parameter">lowmark</code></em></span> <dd> <p class="para"> Low watermark. </p> </dd> </dt> <dt> <span class="term"><em><code class="parameter">highmark</code></em></span> <dd> <p class="para"> High watermark. </p> </dd> </dt> </dl> </p> </div> </div><hr /><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.event-buffer-timeout-set.html">event_buffer_timeout_set</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.event-buffer-write.html">event_buffer_write</a></div> <div class="up"><a href="ref.libevent.html">Libevent Functions</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div></body></html>