ApraLinuxUtils
1.0.0
C++ utility library for embedded Linux systems
Loading...
Searching...
No Matches
Mutex.h
Go to the documentation of this file.
1
/*
2
* Mutex.h
3
*
4
* Copyright (c) 2024 Apra Labs
5
*
6
* This file is part of ApraUtils.
7
*
8
* Licensed under the MIT License.
9
* See LICENSE file in the project root for full license information.
10
*/
11
12
#ifndef SRC_APRA_UTILS_MUTEX_H_
13
#define SRC_APRA_UTILS_MUTEX_H_
14
#include <pthread.h>
15
16
namespace
apra
17
{
18
class
Mutex
19
{
20
public
:
21
friend
class
ScopeLock
;
22
Mutex
();
23
~Mutex
();
24
void
lock
();
25
void
unlock
();
26
protected
:
27
pthread_mutex_t&
get
();
28
pthread_mutex_t
m_mutex
;
29
};
30
}
/* namespace apra */
31
32
#endif
/* SRC_APRA_UTILS_MUTEX_H_ */
apra::Mutex
Definition
Mutex.h:19
apra::Mutex::~Mutex
~Mutex()
Definition
Mutex.cpp:21
apra::Mutex::get
pthread_mutex_t & get()
Definition
Mutex.cpp:33
apra::Mutex::m_mutex
pthread_mutex_t m_mutex
Definition
Mutex.h:28
apra::Mutex::lock
void lock()
Definition
Mutex.cpp:25
apra::Mutex::unlock
void unlock()
Definition
Mutex.cpp:29
apra::Mutex::Mutex
Mutex()
Definition
Mutex.cpp:17
apra::ScopeLock
Definition
ScopeLock.h:23
apra
Definition
EventCallbacks.h:16
includes
utils
Mutex.h
Generated by
1.9.8