Protium
Math and Design Features
 All Classes Namespaces Files Functions Variables Typedefs Enumerator Friends Macros Pages
Protium::Threads::InstanceLocked< Host, MutexPolicy > Class Template Reference

Use to specify instance-locked items. More...

#include <ThreadingPolicy.h>

Inheritance diagram for Protium::Threads::InstanceLocked< Host, MutexPolicy >:

Classes

class  Lock
 

Public Member Functions

 InstanceLocked ()
 Defaults to Mutex being unlocked. More...
 
 InstanceLocked (const InstanceLocked &)
 On copy, the copy instance is unlocked. More...
 
 ~InstanceLocked ()
 Destruction unlocks class. More...
 

Private Attributes

MutexPolicy fMtx
 Contains the mutex used to lock this class. More...
 

Friends

class Lock
 Lock is friended to the host. More...
 

Additional Inherited Members

- Public Types inherited from Protium::Threads::ThreadingPrototype< Host >
typedef Host VolatileType
 Use to access Host class from derived templates. More...
 

Detailed Description

template<class Host, class MutexPolicy = Mutex>
class Protium::Threads::InstanceLocked< Host, MutexPolicy >

Use to specify instance-locked items.

Definition at line 80 of file ThreadingPolicy.h.

Constructor & Destructor Documentation

template<class Host , class MutexPolicy = Mutex>
Protium::Threads::InstanceLocked< Host, MutexPolicy >::InstanceLocked ( )
inline

Defaults to Mutex being unlocked.

Definition at line 85 of file ThreadingPolicy.h.

template<class Host , class MutexPolicy = Mutex>
Protium::Threads::InstanceLocked< Host, MutexPolicy >::InstanceLocked ( const InstanceLocked< Host, MutexPolicy > &  )
inline

On copy, the copy instance is unlocked.

Definition at line 87 of file ThreadingPolicy.h.

template<class Host , class MutexPolicy = Mutex>
Protium::Threads::InstanceLocked< Host, MutexPolicy >::~InstanceLocked ( )
inline

Destruction unlocks class.

Definition at line 89 of file ThreadingPolicy.h.

Friends And Related Function Documentation

template<class Host , class MutexPolicy = Mutex>
friend class Lock
friend

Lock is friended to the host.

Definition at line 92 of file ThreadingPolicy.h.

Member Data Documentation

template<class Host , class MutexPolicy = Mutex>
MutexPolicy Protium::Threads::InstanceLocked< Host, MutexPolicy >::fMtx
mutableprivate

Contains the mutex used to lock this class.

Definition at line 82 of file ThreadingPolicy.h.