le_semaphore.h
Go to the documentation of this file.
1 
91 #ifndef LEGATO_SEMAPHORE_INCLUDE_GUARD
92 #define LEGATO_SEMAPHORE_INCLUDE_GUARD
93 
94 //--------------------------------------------------------------------------------------------------
99 //--------------------------------------------------------------------------------------------------
100 typedef struct le_sem_t* le_sem_Ref_t;
101 
102 //--------------------------------------------------------------------------------------------------
108 //--------------------------------------------------------------------------------------------------
110 (
111  const char* name,
112  int32_t initialCount
113 );
114 
115 //--------------------------------------------------------------------------------------------------
121 //--------------------------------------------------------------------------------------------------
123 (
124  const char* name,
125  int32_t initialCount
126 );
127 
128 //--------------------------------------------------------------------------------------------------
133 //--------------------------------------------------------------------------------------------------
134 void le_sem_Delete
135 (
136  le_sem_Ref_t semaphorePtr
137 );
138 
139 //--------------------------------------------------------------------------------------------------
146 //--------------------------------------------------------------------------------------------------
148 (
149  const char* name
150 );
151 
152 //--------------------------------------------------------------------------------------------------
158 //--------------------------------------------------------------------------------------------------
159 void le_sem_Wait
160 (
161  le_sem_Ref_t semaphorePtr
162 );
163 
164 //--------------------------------------------------------------------------------------------------
174 //--------------------------------------------------------------------------------------------------
176 (
177  le_sem_Ref_t semaphorePtr
178 );
179 
180 //--------------------------------------------------------------------------------------------------
190 //--------------------------------------------------------------------------------------------------
192 (
193  le_sem_Ref_t semaphorePtr,
194  le_clk_Time_t timeToWait
195 );
196 
197 //--------------------------------------------------------------------------------------------------
203 //--------------------------------------------------------------------------------------------------
204 void le_sem_Post
205 (
206  le_sem_Ref_t semaphorePtr
207 );
208 
209 //--------------------------------------------------------------------------------------------------
215 //--------------------------------------------------------------------------------------------------
216 int le_sem_GetValue
217 (
218  le_sem_Ref_t semaphorePtr
219 );
220 
221 #endif // LEGATO_SEMAPHORE_INCLUDE_GUARD
le_result_t le_sem_TryWait(le_sem_Ref_t semaphorePtr)
le_result_t
Definition: le_basics.h:35
struct le_sem_t * le_sem_Ref_t
Definition: le_semaphore.h:100
le_sem_Ref_t le_sem_FindSemaphore(const char *name)
le_sem_Ref_t le_sem_CreateTraceable(const char *name, int32_t initialCount)
void le_sem_Post(le_sem_Ref_t semaphorePtr)
Definition: le_clock.h:92
void le_sem_Delete(le_sem_Ref_t semaphorePtr)
void le_sem_Wait(le_sem_Ref_t semaphorePtr)
le_result_t le_sem_WaitWithTimeOut(le_sem_Ref_t semaphorePtr, le_clk_Time_t timeToWait)
le_sem_Ref_t le_sem_Create(const char *name, int32_t initialCount)
int le_sem_GetValue(le_sem_Ref_t semaphorePtr)