Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TGLLockable Class Reference

Simple locking interface used by viewer and scene.

Definition at line 17 of file TGLLockable.h.

Classes

class  TUnlocker
 

Public Types

enum  ELock { kUnlocked , kDrawLock , kSelectLock , kModifyLock }
 

Public Member Functions

 TGLLockable ()
 
virtual ~TGLLockable ()
 
ELock CurrentLock () const
 
virtual TClassIsA () const
 
Bool_t IsDrawOrSelectLock () const
 
Bool_t IsLocked () const
 
virtual const char * LockIdStr () const
 
Bool_t ReleaseLock (ELock lock) const
 Release current lock, make sure it the same as the 'lock' argument.
 
virtual void Streamer (TBuffer &)
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 
Bool_t TakeLock (ELock lock) const
 Lock the object in mode 'lock'.
 

Static Public Member Functions

static TClassClass ()
 
static const char * Class_Name ()
 
static constexpr Version_t Class_Version ()
 
static const char * DeclFileName ()
 
static const char * LockName (ELock lock)
 Return name-string for given lock-type.
 
static Bool_t LockValid (ELock lock)
 Test if lock is a valid type to take/release.
 

Protected Attributes

ELock fLock
 

Private Member Functions

 TGLLockable (const TGLLockable &)=delete
 
TGLLockableoperator= (const TGLLockable &)=delete
 

#include <TGLLockable.h>

Inheritance diagram for TGLLockable:
[legend]

Member Enumeration Documentation

◆ ELock

Enumerator
kUnlocked 
kDrawLock 
kSelectLock 
kModifyLock 

Definition at line 20 of file TGLLockable.h.

Constructor & Destructor Documentation

◆ TGLLockable() [1/2]

TGLLockable::TGLLockable ( const TGLLockable )
privatedelete

◆ TGLLockable() [2/2]

TGLLockable::TGLLockable ( )

Definition at line 22 of file TGLLockable.cxx.

◆ ~TGLLockable()

virtual TGLLockable::~TGLLockable ( )
inlinevirtual

Definition at line 54 of file TGLLockable.h.

Member Function Documentation

◆ Class()

static TClass * TGLLockable::Class ( )
static
Returns
TClass describing this class

◆ Class_Name()

static const char * TGLLockable::Class_Name ( )
static
Returns
Name of this class

◆ Class_Version()

static constexpr Version_t TGLLockable::Class_Version ( )
inlinestaticconstexpr
Returns
Version of this class

Definition at line 68 of file TGLLockable.h.

◆ CurrentLock()

ELock TGLLockable::CurrentLock ( ) const
inline

Definition at line 61 of file TGLLockable.h.

◆ DeclFileName()

static const char * TGLLockable::DeclFileName ( )
inlinestatic
Returns
Name of the file containing the class declaration

Definition at line 68 of file TGLLockable.h.

◆ IsA()

virtual TClass * TGLLockable::IsA ( ) const
inlinevirtual
Returns
TClass describing current object

Reimplemented in TGLEmbeddedViewer, TGLSAViewer, TGLScene, TGLSceneBase, TGLScenePad, TGLViewer, and TGLViewerBase.

Definition at line 68 of file TGLLockable.h.

◆ IsDrawOrSelectLock()

Bool_t TGLLockable::IsDrawOrSelectLock ( ) const
inline

Definition at line 63 of file TGLLockable.h.

◆ IsLocked()

Bool_t TGLLockable::IsLocked ( ) const
inline

Definition at line 60 of file TGLLockable.h.

◆ LockIdStr()

virtual const char * TGLLockable::LockIdStr ( ) const
inlinevirtual

Reimplemented in TGLSceneBase, and TGLViewerBase.

Definition at line 56 of file TGLLockable.h.

◆ LockName()

const char * TGLLockable::LockName ( ELock  lock)
static

Return name-string for given lock-type.

Definition at line 69 of file TGLLockable.cxx.

◆ LockValid()

Bool_t TGLLockable::LockValid ( ELock  lock)
static

Test if lock is a valid type to take/release.

kUnlocked is never valid in these cases.

Definition at line 85 of file TGLLockable.cxx.

◆ operator=()

TGLLockable & TGLLockable::operator= ( const TGLLockable )
privatedelete

◆ ReleaseLock()

Bool_t TGLLockable::ReleaseLock ( ELock  lock) const

Release current lock, make sure it the same as the 'lock' argument.

Returns TRUE on success, FALSE on failure.

Definition at line 51 of file TGLLockable.cxx.

◆ Streamer()

virtual void TGLLockable::Streamer ( TBuffer )
virtual

◆ StreamerNVirtual()

void TGLLockable::StreamerNVirtual ( TBuffer ClassDef_StreamerNVirtual_b)
inline

Definition at line 68 of file TGLLockable.h.

◆ TakeLock()

Bool_t TGLLockable::TakeLock ( ELock  lock) const

Lock the object in mode 'lock'.

Return TRUE if successful, FALSE if the object is already locked.

Definition at line 32 of file TGLLockable.cxx.

Member Data Documentation

◆ fLock

ELock TGLLockable::fLock
mutableprotected

Definition at line 32 of file TGLLockable.h.

Libraries for TGLLockable:

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