libjmmcg  release_579_6_g8cffd
A C++ library containing an eclectic mix of useful, advanced components.
jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject > Class Template Reference

#include <locking.hpp>

Inheritance diagram for jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >:
[legend]
Collaboration diagram for jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >:
[legend]

Public Types

typedef lockable< typename LockObject::lock_traits > base_t
 
typedef LockObject atomic_t
 
typedef atomic_t::lock_traits lock_traits
 
typedef lock_traits::atomic_state_type atomic_state_type
 
typedef lock_traits::timeout_type timeout_type
 
typedef atomic_state_type lock_result_type
 
- Public Types inherited from jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::lockable< LockObject::lock_traits >
using lock_traits = LockObject::lock_traits
 
typedef lock_traits::atomic_state_type atomic_state_type
 
typedef lock_traits::timeout_type timeout_type
 

Static Public Attributes

static constexpr generic_traits::memory_access_modes memory_access_mode =atomic_t::memory_access_mode
 

Protected Member Functions

__stdcall scope_lock (atomic_t &lo) noexcept(true) FORCE_INLINE
 
__stdcall scope_lock (atomic_t &lo, const timeout_type period) noexcept(true) FORCE_INLINE
 
 scope_lock (scope_lock const &)=delete
 
virtual __stdcall ~scope_lock () noexcept(true) FORCE_INLINE
 
lock_result_type __fastcall try_lock () noexcept(true) override FORCE_INLINE
 
lock_result_type __fastcall lock () noexcept(false) override FORCE_INLINE
 
lock_result_type __fastcall lock (const timeout_type period) noexcept(false) override FORCE_INLINE
 
lock_result_type __fastcall unlock () noexcept(true) override FORCE_INLINE
 
void decay () noexcept(true) FORCE_INLINE
 

Protected Attributes

atomic_tlocker
 

Additional Inherited Members

Detailed Description

template<class LockObject>
class jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >

Definition at line 86 of file locking.hpp.

Member Typedef Documentation

◆ atomic_state_type

template<class LockObject >
typedef lock_traits::atomic_state_type jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::atomic_state_type

Definition at line 91 of file locking.hpp.

◆ atomic_t

template<class LockObject >
typedef LockObject jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::atomic_t

Definition at line 89 of file locking.hpp.

◆ base_t

template<class LockObject >
typedef lockable<typename LockObject::lock_traits> jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::base_t

Definition at line 88 of file locking.hpp.

◆ lock_result_type

Definition at line 93 of file locking.hpp.

◆ lock_traits

template<class LockObject >
typedef atomic_t::lock_traits jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::lock_traits

Definition at line 90 of file locking.hpp.

◆ timeout_type

template<class LockObject >
typedef lock_traits::timeout_type jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::timeout_type

Definition at line 92 of file locking.hpp.

Constructor & Destructor Documentation

◆ scope_lock() [1/3]

template<class LockObject >
jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::scope_lock ( atomic_t lo)
inlineexplicitprotectednoexcept

◆ scope_lock() [2/3]

template<class LockObject >
jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::scope_lock ( atomic_t lo,
const timeout_type  period 
)
inlineprotectednoexcept

◆ scope_lock() [3/3]

template<class LockObject >
jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::scope_lock ( scope_lock< LockObject > const &  )
protecteddelete

◆ ~scope_lock()

template<class LockObject >
jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::~scope_lock
inlineprotectedvirtualnoexcept

Member Function Documentation

◆ decay()

template<class LockObject >
void jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::decay
inlineprotectednoexcept

◆ lock() [1/2]

◆ lock() [2/2]

◆ try_lock()

◆ unlock()

Member Data Documentation

◆ locker

◆ memory_access_mode

template<class LockObject >
constexpr generic_traits::memory_access_modes jmmcg::LIBJMMCG_VER_NAMESPACE::ppd::lock::scope_lock< LockObject >::memory_access_mode =atomic_t::memory_access_mode
staticconstexpr

To assist in allowing compile-time computation of the algorithmic order of the threading model.

Definition at line 98 of file locking.hpp.


The documentation for this class was generated from the following files: