AJA NTV2 SDK  17.5.0.1242
NTV2 SDK 17.5.0.1242
lockimpl.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: MIT */
8 #ifndef AJA_LOCK_IMPL_H
9 #define AJA_LOCK_IMPL_H
10 
11 #include <pthread.h>
12 #include "ajabase/system/system.h"
13 #include "ajabase/common/common.h"
14 #include "ajabase/system/lock.h"
15 
16 class AJALockImpl
17 {
18 public:
19 
20  AJALockImpl(const char* pName);
21  virtual ~AJALockImpl();
22 
23  AJAStatus Lock(uint32_t uTimeout = 0xffffffff);
24  AJAStatus Unlock();
25 
26 private:
27  const char* mName;
28  pthread_t mOwner;
29  int mRefCount;
30  pthread_mutex_t mMutex; // For protecting the member variables
31 };
32 
33 #endif // AJA_LOCK_IMPL_H
AJALockImpl::~AJALockImpl
virtual ~AJALockImpl()
Definition: lockimpl.cpp:72
AJALockImpl::Unlock
AJAStatus Unlock()
Definition: lockimpl.cpp:143
AJALockImpl
Definition: lockimpl.h:18
AJAStatus
AJAStatus
Definition: types.h:378
lock.h
Declares the AJALock class.
AJALockImpl::Lock
AJAStatus Lock(uint32_t uTimeout=0xffffffff)
Definition: lockimpl.cpp:87
system.h
System specific functions.
common.h
Private include file for all ajabase sources.
AJALockImpl::AJALockImpl
AJALockImpl(const char *pName)
Definition: lockimpl.cpp:20