<!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>The Threaded interface</title> </head> <body><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="pht-atomicinteger.unlock.html">pht\AtomicInteger::unlock</a></div> <div class="next" style="text-align: right; float: right;"><a href="pht-threaded.lock.html">pht\Threaded::lock</a></div> <div class="up"><a href="book.pht.html">pht</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div><hr /><div id="class.pht-threaded" class="reference"> <h1 class="title">The Threaded interface</h1> <div class="partintro"><p class="verinfo">(PECL pht >= 0.0.1)</p> <div class="section" id="pht-threaded.intro"> <h2 class="title">Introduction</h2> <p class="para"> The <span class="interfacename"><strong class="interfacename">pht\Threaded</strong></span> interface is an internal interface used by the Inter-Thread Communication (ITC) data structures (<a href="class.pht-hashtable.html" class="classname">pht\HashTable</a>, <a href="class.pht-queue.html" class="classname">pht\Queue</a>, and <a href="class.pht-vector.html" class="classname">pht\Vector</a>). It allows those data structures to be threaded and ensures that the mutex locking API (<span class="methodname"><a href="pht-threaded.lock.html" class="methodname">pht\Threaded::lock()</a></span> and <span class="methodname"><a href="pht-threaded.unlock.html" class="methodname">pht\Threaded::unlock()</a></span>) is implemented by each of the ITC data structures. It is not implementable by userland classes (since standalone mutex locks are not exposed). </p> </div> <div class="section" id="pht-threaded.synopsis"> <h2 class="title">Interface synopsis</h2> <div class="classsynopsis"> <div class="ooclass"></div> <div class="classsynopsisinfo"> <span class="ooclass"> <strong class="classname">pht\Threaded</strong> </span> {</div> <div class="classsynopsisinfo classsynopsisinfo_comment">/* Methods */</div> <div class="methodsynopsis dc-description"> <span class="modifier">public</span> <span class="type">void</span> <span class="methodname"><a href="pht-threaded.lock.html" class="methodname">lock</a></span> ( <span class="methodparam">void</span> )</div> <div class="methodsynopsis dc-description"> <span class="modifier">public</span> <span class="type">void</span> <span class="methodname"><a href="pht-threaded.unlock.html" class="methodname">unlock</a></span> ( <span class="methodparam">void</span> )</div> }</div> </div> </div> <h2>Table of Contents</h2><ul class="chunklist chunklist_reference"><li><a href="pht-threaded.lock.html">pht\Threaded::lock</a> — Acquires the mutex lock</li><li><a href="pht-threaded.unlock.html">pht\Threaded::unlock</a> — Releases the mutex lock</li></ul> </div> <hr /><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="pht-atomicinteger.unlock.html">pht\AtomicInteger::unlock</a></div> <div class="next" style="text-align: right; float: right;"><a href="pht-threaded.lock.html">pht\Threaded::lock</a></div> <div class="up"><a href="book.pht.html">pht</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div></body></html>