xtd 0.2.0
Loading...
Searching...
No Matches
unnamed_mutex.h
Go to the documentation of this file.
1
4#pragma once
6#if !defined(__XTD_CORE_NATIVE_LIBRARY__)
7#error "Do not include this file: Internal use only"
8#endif
10
11#include <xtd/core_native_export>
12#include <cstddef>
13#include <cstdint>
14#include <string>
15
17namespace xtd {
19 namespace threading {
20 class mutex;
21 }
23
26 namespace native {
35 class core_native_export_ unnamed_mutex final {
36 unnamed_mutex() = delete;
38 protected:
40
47 static intmax_t create(bool initially_owned);
48
53 static void destroy(intmax_t handle);
54
59 static bool signal(intmax_t handle, bool& io_error);
60
70 static uint32_t wait(intmax_t handle, int32_t milliseconds_timeout);
72 };
73 }
74}
Contains unnamed_mutex native API.
Definition unnamed_mutex.h:35
static intmax_t create(bool initially_owned)
Create named mutex with specified name and a bool value that.
static uint32_t wait(intmax_t handle, int32_t milliseconds_timeout)
Wait named mutex with specified mutex handle and timeout.
static void destroy(intmax_t handle)
Destroy named mutex with specified mutex handle.
static bool signal(intmax_t handle, bool &io_error)
Signal named mutex with specified mutex handle.
A synchronization primitive that can also be used for interprocess synchronization.
Definition mutex.h:50
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition xtd_about_box.h:10