]> git.tdb.fi Git - libs/core.git/blob - source/core/semaphore.h
Add move semantics to Variant
[libs/core.git] / source / core / semaphore.h
1 #ifndef MSP_CORE_SEMAPHORE_H_
2 #define MSP_CORE_SEMAPHORE_H_
3
4 #include <msp/time/timedelta.h>
5 #include "mspcore_api.h"
6 #include "noncopyable.h"
7
8 namespace Msp {
9
10 class MSPCORE_API Semaphore: private NonCopyable
11 {
12 private:
13         struct Private;
14
15         Private *priv = nullptr;
16
17 public:
18         Semaphore(unsigned);
19         ~Semaphore();
20
21         void signal();
22         void wait();
23         bool wait(const Time::TimeDelta &);
24 };
25
26 }
27
28 #endif