Alexandria 2.32.0
SDC-CH common library for the Euclid project
Loading...
Searching...
No Matches
Euclid::Semaphore::SemaphoreImpl Class Reference

Public Member Functions

 SemaphoreImpl (unsigned int i)
 ~SemaphoreImpl ()
void post ()
void wait ()
bool try_acquire ()
bool try_acquire_until (std::chrono::system_clock::time_point abs_time)
 SemaphoreImpl (unsigned int i)
 ~SemaphoreImpl ()
void post ()
void wait ()
bool try_acquire ()
bool try_acquire_until (std::chrono::system_clock::time_point abs_time)

Private Member Functions

bool timed_wait (const mach_timespec_t &wait)

Private Attributes

semaphore_t m_semaphore
sem_t m_semaphore

Detailed Description

Definition at line 27 of file SemaphoreMach.icpp.

Constructor & Destructor Documentation

◆ SemaphoreImpl() [1/2]

Euclid::Semaphore::SemaphoreImpl::SemaphoreImpl ( unsigned int i)
inlineexplicit

Definition at line 29 of file SemaphoreMach.icpp.

References m_semaphore, and std::system_category().

Here is the call graph for this function:

◆ ~SemaphoreImpl() [1/2]

Euclid::Semaphore::SemaphoreImpl::~SemaphoreImpl ( )
inline

Definition at line 36 of file SemaphoreMach.icpp.

References m_semaphore.

◆ SemaphoreImpl() [2/2]

Euclid::Semaphore::SemaphoreImpl::SemaphoreImpl ( unsigned int i)
inlineexplicit

Definition at line 26 of file SemaphorePosix.icpp.

References m_semaphore, and std::system_category().

Here is the call graph for this function:

◆ ~SemaphoreImpl() [2/2]

Euclid::Semaphore::SemaphoreImpl::~SemaphoreImpl ( )
inline

Definition at line 32 of file SemaphorePosix.icpp.

References m_semaphore.

Member Function Documentation

◆ post() [1/2]

void Euclid::Semaphore::SemaphoreImpl::post ( )
inline

Definition at line 40 of file SemaphoreMach.icpp.

References m_semaphore, and std::system_category().

Here is the call graph for this function:

◆ post() [2/2]

void Euclid::Semaphore::SemaphoreImpl::post ( )
inline

Definition at line 36 of file SemaphorePosix.icpp.

References m_semaphore, and std::system_category().

Here is the call graph for this function:

◆ timed_wait()

bool Euclid::Semaphore::SemaphoreImpl::timed_wait ( const mach_timespec_t & wait)
inlineprivate

Definition at line 80 of file SemaphoreMach.icpp.

References m_semaphore, std::system_category(), and wait().

Referenced by try_acquire(), and try_acquire_until().

Here is the call graph for this function:

◆ try_acquire() [1/2]

bool Euclid::Semaphore::SemaphoreImpl::try_acquire ( )
inline

Definition at line 59 of file SemaphoreMach.icpp.

References timed_wait(), and wait().

Here is the call graph for this function:

◆ try_acquire() [2/2]

bool Euclid::Semaphore::SemaphoreImpl::try_acquire ( )
inline

Definition at line 48 of file SemaphorePosix.icpp.

References m_semaphore, and std::system_category().

Here is the call graph for this function:

◆ try_acquire_until() [1/2]

bool Euclid::Semaphore::SemaphoreImpl::try_acquire_until ( std::chrono::system_clock::time_point abs_time)
inline

Definition at line 64 of file SemaphoreMach.icpp.

References std::chrono::duration_cast(), std::chrono::system_clock::now(), timed_wait(), and wait().

Here is the call graph for this function:

◆ try_acquire_until() [2/2]

bool Euclid::Semaphore::SemaphoreImpl::try_acquire_until ( std::chrono::system_clock::time_point abs_time)
inline

Definition at line 58 of file SemaphorePosix.icpp.

References m_semaphore, std::system_category(), and std::chrono::time_point_cast().

Here is the call graph for this function:

◆ wait() [1/2]

void Euclid::Semaphore::SemaphoreImpl::wait ( )
inline

Definition at line 46 of file SemaphoreMach.icpp.

References m_semaphore, and std::system_category().

Referenced by timed_wait(), try_acquire(), and try_acquire_until().

Here is the call graph for this function:

◆ wait() [2/2]

void Euclid::Semaphore::SemaphoreImpl::wait ( )
inline

Definition at line 42 of file SemaphorePosix.icpp.

References m_semaphore, and std::system_category().

Here is the call graph for this function:

Member Data Documentation

◆ m_semaphore [1/2]

semaphore_t Euclid::Semaphore::SemaphoreImpl::m_semaphore
private

◆ m_semaphore [2/2]

sem_t Euclid::Semaphore::SemaphoreImpl::m_semaphore
private

Definition at line 77 of file SemaphorePosix.icpp.


The documentation for this class was generated from the following files: