VR-Link API Documentation for DIS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Attributes
DtThreadSafe< T >::ConstLockedProxy Class Reference

Private class that provides a locked call to the const object. More...

+ Collaboration diagram for DtThreadSafe< T >::ConstLockedProxy:

Public Member Functions

 ConstLockedProxy (const T &value, DtMutex &mutex)
 Constructor. More...
 
 ConstLockedProxy (const ConstLockedProxy &orig)
 Copy Constructor, should not be necessary for optimized code. More...
 
 ~ConstLockedProxy ()
 Destructor, releases lock. More...
 
const T * operator-> ()
 Pointer redirect operator. More...
 

Protected Attributes

const T * myValue
 
DtMutexmyMutex
 
DtScopedLock myLock
 

Detailed Description

template<typename T>
class DtThreadSafe< T >::ConstLockedProxy

Private class that provides a locked call to the const object.

This class should not be extended.

Constructor & Destructor Documentation

template<typename T>
DtThreadSafe< T >::ConstLockedProxy::ConstLockedProxy ( const T &  value,
DtMutex mutex 
)

Constructor.

template<typename T>
DtThreadSafe< T >::ConstLockedProxy::ConstLockedProxy ( const ConstLockedProxy orig)

Copy Constructor, should not be necessary for optimized code.

template<typename T>
DtThreadSafe< T >::ConstLockedProxy::~ConstLockedProxy ( )

Destructor, releases lock.

Member Function Documentation

template<typename T>
const T* DtThreadSafe< T >::ConstLockedProxy::operator-> ( )

Pointer redirect operator.

This allows access to the locked object. A pointer to the object should NOT be stored, or passed to functions unless they are known to not maintain a copy.

Member Data Documentation

template<typename T>
DtScopedLock DtThreadSafe< T >::ConstLockedProxy::myLock
protected
template<typename T>
DtMutex& DtThreadSafe< T >::ConstLockedProxy::myMutex
protected
template<typename T>
const T* DtThreadSafe< T >::ConstLockedProxy::myValue
protected

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

Document ID: Generated on Tue Feb 2 21:02:17 EST 2021 from SVN revision 223668
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)