11#ifndef __BE_PROCESS_SEMAPHORE_H__
12#define __BE_PROCESS_SEMAPHORE_H__
68 const std::string &name,
71 const bool force =
false);
85 const std::string &name);
102 bool wait(
const bool interruptible);
139 const uint64_t interval,
140 const bool interruptible);
Represent a semaphore that can be used for interprocess communication.
Semaphore(const std::string &name)
Open an existing named sempahore.
void post()
Post (increment) to the semaphore.
bool trywait(const bool interruptible)
Attempt to obtain the semaphore without blocking.
std::string getName()
Obtain the name of the Semaphore.
Semaphore(const std::string &name, const mode_t mode, const int value, const bool force=false)
Create a new named sempahore.
bool wait(const bool interruptible)
Wait indefinitely for the semaphore to unblock.
bool timedwait(const uint64_t interval, const bool interruptible)
Attempt to obtain the semaphore while blocking for at most the specified time interval.
This software was developed at the National Institute of Standards and Technology (NIST) by employees...