blob: 75be93bdc39e1d72e4f113e44290b2076e8fb777 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>oscl_semaphore.h Source File</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.2.18 -->
<center>
<a class="qindex" href="index.html">Main Page</a> &nbsp; <a class="qindex" href="modules.html">Modules</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="annotated.html">Data Structures</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="functions.html">Data Fields</a> &nbsp; <a class="qindex" href="globals.html">Globals</a> &nbsp; </center>
<hr><h1>oscl_semaphore.h</h1><a href="oscl__semaphore_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <span class="comment">// -*- c++ -*-</span>
00002 <span class="comment">// = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =</span>
00003
00004 <span class="comment">// O S C L _ S E M A P H O R E</span>
00005
00006 <span class="comment">// = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =</span>
00007
00014 <span class="comment">// Definition file for OSCL Semaphore</span>
00015 <span class="preprocessor">#ifndef OSCL_SEMAPHORE_H_INCLUDED</span>
00016 <span class="preprocessor"></span><span class="preprocessor">#define OSCL_SEMAPHORE_H_INCLUDED</span>
00017 <span class="preprocessor"></span>
00018 <span class="preprocessor">#ifndef OSCLCONFIG_PROC_H_INCLUDED</span>
00019 <span class="preprocessor"></span><span class="preprocessor">#include "<a class="code" href="osclconfig__proc_8h.html">osclconfig_proc.h</a>"</span>
00020 <span class="preprocessor">#endif</span>
00021 <span class="preprocessor"></span>
00022 <span class="preprocessor">#ifndef OSCL_THREAD_H_INCLUDED</span>
00023 <span class="preprocessor"></span><span class="preprocessor">#include "<a class="code" href="oscl__thread_8h.html">oscl_thread.h</a>"</span>
00024 <span class="preprocessor">#endif</span>
00025 <span class="preprocessor"></span>
00026
<a name="l00030"></a><a class="code" href="classOsclSemaphore.html">00030</a> <span class="keyword">class </span><a class="code" href="classOsclSemaphore.html">OsclSemaphore</a>
00031 {
00032 <span class="keyword">public</span>:
00033
00037 OSCL_IMPORT_REF <a class="code" href="classOsclSemaphore.html#a0">OsclSemaphore</a>();
00038
00042 OSCL_IMPORT_REF <a class="code" href="classOsclSemaphore.html#a1">~OsclSemaphore</a>();
00043
00052 OSCL_IMPORT_REF <a class="code" href="classOsclProcStatus.html#s35">OsclProcStatus::eOsclProcError</a> <a class="code" href="classOsclSemaphore.html#a2">Create</a>(uint32 initVal = 0);
00053
00062 OSCL_IMPORT_REF <a class="code" href="classOsclProcStatus.html#s35">OsclProcStatus::eOsclProcError</a> <a class="code" href="classOsclSemaphore.html#a3">Close</a>();
00063
00072 OSCL_IMPORT_REF <a class="code" href="classOsclProcStatus.html#s35">OsclProcStatus::eOsclProcError</a> <a class="code" href="classOsclSemaphore.html#a4">Wait</a>();
00073
00085 OSCL_IMPORT_REF <a class="code" href="classOsclProcStatus.html#s35">OsclProcStatus::eOsclProcError</a> <a class="code" href="classOsclSemaphore.html#a4">Wait</a>(uint32 timeout_msec);
00086
00099 OSCL_IMPORT_REF <a class="code" href="classOsclProcStatus.html#s35">OsclProcStatus::eOsclProcError</a> <a class="code" href="classOsclSemaphore.html#a6">TryWait</a>();
00100
00109 OSCL_IMPORT_REF <a class="code" href="classOsclProcStatus.html#s35">OsclProcStatus::eOsclProcError</a> <a class="code" href="classOsclSemaphore.html#a7">Signal</a>();
00110
00111 <span class="keyword">private</span>:
00112
00113
00114
00115 <span class="keywordtype">bool</span> bCreated;
00116 <span class="comment">//for pthreads implementations without sem timedwait support.</span>
00117 TOsclMutexObject ObjMutex;
00118 TOsclConditionObject ObjCondition;
00119 uint32 iCount;
00120
00121
00122 };
00123
00124
00125
00126
00127
00128 <span class="preprocessor">#endif // END OF File</span>
00129 <span class="preprocessor"></span>
</pre></div><hr size="1"><img src="pvlogo_small.jpg"><address style="align: right;"><small>OSCL API</small>
<address style="align: left;"><small>Posting Version: OPENCORE_20090310 </small>
</small></address>
</body>
</html>