<html> <head> <title>class Semaphore</title> <link rel="stylesheet" type="text/css" href="../../cpp.css"> </head> <body> <div id="adc-cppref"> <a name="_top_"> </a><table class="navimain" border="0" cellpadding="1" cellspacing="0"> <tr align="center" valign="top"> <td class="navimain"> <a href="../../index.html">Overview</a> </td> <td class="navimain"> <a href="index.html">Namespace</a> </td> <td class="navimainself"> Class </td> <td class="navimain"> <a href="../../index-files/index-1.html">Index</a> </td> <td class="navimain"> <a href="../../help.html">Help</a> </td> </tr> </table> <table class="navisub" cellpadding="0" cellspacing="3"> <tr> <td width="20%"><font size="-2">PUBLIC MEMBERS:</font></td> <td> <font size="-2">CLASSES</font> | <font size="-2">STRUCTS</font> | <font size="-2">UNIONS</font> | <font size="-2">ENUMS</font> | <font size="-2">TYPEDEFS</font> | <a href="#publ_ops"><font size="-2"><b>METHODS</b></font></a> | <font size="-2">STATIC METHODS</font> | <font size="-2">DATA</font> | <font size="-2">STATIC DATA</font></td> </tr> <tr> <td width="20%"><font size="-2">PRIVATE MEMBERS:</font></td> <td> <font size="-2">CLASSES</font> | <font size="-2">STRUCTS</font> | <font size="-2">UNIONS</font> | <font size="-2">ENUMS</font> | <font size="-2">TYPEDEFS</font> | <a href="#priv_ops"><font size="-2"><b>METHODS</b></font></a> | <font size="-2">STATIC METHODS</font> | <a href="#priv_vars"><font size="-2"><b>DATA</b></font></a> | <font size="-2">STATIC DATA</font></td> </tr> </table> <hr> <a href="../../names/index.html" alt="Global Namespace in C++"><font size="+1"><b>::</b></font></a> <a href="index.html" alt="namespace"><font size="+1"><b>osl</b></font></a><font size="+1"> :: </font><div class="title"><h2>class Semaphore</h2> </div><hr> <dl> <dt>Base Classes</dt> <dd>None.</dd> </dl> <dl> <dt>Known Derived Classes</dt> <dd>None.</dd> </dl> <br> <table class="flag-table" border="1" cellspacing="0"> <tr> <td width="25%" class="flagname">virtual</td> <td width="25%" class="flagname">abstract</td> <td width="25%" class="flagname">interface</td> <td width="25%" class="flagname">template</td> </tr> <tr> <td class="flagno">NO</td> <td class="flagno">NO</td> <td class="flagno">NO</td> <td class="flagno">NO</td> </tr> </table> <dl> <dt>File</dt> <dd>semaphor.hxx</dd> </dl> <hr> <dl> <dt class="subtitle"><a name="publ_"><h3>Public Members</h3> </a></dt> <dd><a name="publ_ops"> </a><table class="childlist" border="1" cellpadding="5" cellspacing="0" width="100%"> <tr class="subtitle"> <td colspan="2"><h4>Methods</h4> </td> </tr> <tr> <td> <br> <a href="Semaphore/o.html#Semaphore-264">Semaphore</a>( sal_uInt32 initialCount );</td> <td width="50%"> Creates a semaphore.<BR> </td> </tr> <tr> <td> <br> <a href="Semaphore/o.html#~Semaphore-265">~Semaphore</a>( );</td> <td width="50%"> Release the OS-structures and free semaphore data-structure </td> </tr> <tr> <td>sal_Bool <br> <a href="Semaphore/o.html#acquire-266">acquire</a>( );</td> <td width="50%"> acquire()decreases the count. It will block if it tries to decrease below zero. </td> </tr> <tr> <td>sal_Bool <br> <a href="Semaphore/o.html#tryToAcquire-267">tryToAcquire</a>( );</td> <td width="50%"> </td> </tr> <tr> <td>sal_Bool <br> <a href="Semaphore/o.html#release-268">release</a>( );</td> <td width="50%"> release()increases the count. </td> </tr> </table> <hr> </dd> </dl> <dl> <dt class="subtitle"><a name="priv_"><h3>Private Members</h3> </a></dt> <dd><a name="priv_ops"> </a><table class="childlist" border="1" cellpadding="5" cellspacing="0" width="100%"> <tr class="subtitle"> <td colspan="2"><h4>Methods</h4> </td> </tr> <tr> <td> <br> <a href="Semaphore/o.html#Semaphore-270">Semaphore</a>( const Semaphore & );</td> <td width="50%"> The underlying oslSemaphore has no reference count. </td> </tr> <tr> <td> <br> <a href="Semaphore/o.html#Semaphore-271">Semaphore</a>( oslSemaphore Semaphore );</td> <td width="50%"> The underlying oslSemaphore has no reference count. </td> </tr> <tr> <td>Semaphore & <br> <a href="Semaphore/o.html#operator=-272">operator=</a>( const Semaphore & );</td> <td width="50%"> This assignment operator is private for the same reason as the copy constructor. </td> </tr> <tr> <td>Semaphore & <br> <a href="Semaphore/o.html#operator=-273">operator=</a>( oslSemaphore );</td> <td width="50%"> This assignment operator is private for the same reason as the constructor taking a oslSemaphore argument. </td> </tr> </table> <hr> <a name="priv_vars"> </a><table class="childlist" border="1" cellpadding="5" cellspacing="0" width="100%"> <tr class="subtitle"> <td colspan="2"><h4>Data</h4> </td> </tr> <tr bgcolor="white"> <td><a href="../t-oslSemaphore.html">oslSemaphore</a> <a href="Semaphore/d.html#semaphore"><strong>semaphore;</strong></a></td> <td/></tr> </table> <hr> </dd> </dl> <a href="#_top_" class="objchapter">Top of Page</a><hr size="3"><p class="copyright" align="center">Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.</p> </div> <!-- id="adc-cppref" --> </body> </html>