XRootD
XrdSsiMutexMon Class Reference

#include <XrdSsiAtomics.hh>

+ Collaboration diagram for XrdSsiMutexMon:

Public Member Functions

 XrdSsiMutexMon (XrdSsiMutex &mutex)
 
 XrdSsiMutexMon (XrdSsiMutex *mutex=0)
 
 ~XrdSsiMutexMon ()
 
void Lock (XrdSsiMutex &mutex)
 
void Lock (XrdSsiMutex *mutex)
 
void Reset ()
 
void UnLock ()
 

Detailed Description

Definition at line 148 of file XrdSsiAtomics.hh.

Constructor & Destructor Documentation

◆ XrdSsiMutexMon() [1/2]

XrdSsiMutexMon::XrdSsiMutexMon ( XrdSsiMutex mutex = 0)
inline

Definition at line 166 of file XrdSsiAtomics.hh.

167  {if (mutex) mutex->Lock();
168  mtx = mutex;
169  }

◆ XrdSsiMutexMon() [2/2]

XrdSsiMutexMon::XrdSsiMutexMon ( XrdSsiMutex mutex)
inline

Definition at line 170 of file XrdSsiAtomics.hh.

171  {mutex.Lock();
172  mtx = &mutex;
173  }

References XrdSsiMutex::Lock().

+ Here is the call graph for this function:

◆ ~XrdSsiMutexMon()

XrdSsiMutexMon::~XrdSsiMutexMon ( )
inline

Definition at line 175 of file XrdSsiAtomics.hh.

175 {if (mtx) UnLock();}

References UnLock().

+ Here is the call graph for this function:

Member Function Documentation

◆ Lock() [1/2]

void XrdSsiMutexMon::Lock ( XrdSsiMutex mutex)
inline

Definition at line 160 of file XrdSsiAtomics.hh.

160 {Lock(&mutex);}
void Lock(XrdSsiMutex *mutex)

References Lock().

Referenced by Lock().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Lock() [2/2]

void XrdSsiMutexMon::Lock ( XrdSsiMutex mutex)
inline

Definition at line 152 of file XrdSsiAtomics.hh.

153  {if (mtx) {if (mtx != mutex) mtx->UnLock();
154  else return;
155  }
156  mutex->Lock();
157  mtx = mutex;
158  };

References XrdSsiMutex::Lock(), and XrdSsiMutex::UnLock().

Referenced by XrdSsiFileReq::Finalize(), and XrdSsiFileReq::WantResponse().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Reset()

void XrdSsiMutexMon::Reset ( )
inline

Definition at line 162 of file XrdSsiAtomics.hh.

162 {mtx = 0;}

Referenced by XrdSsiTaskReal::XeqEvent().

+ Here is the caller graph for this function:

◆ UnLock()

void XrdSsiMutexMon::UnLock ( )
inline

Definition at line 164 of file XrdSsiAtomics.hh.

164 {if (mtx) {mtx->UnLock(); mtx = 0;}}

References XrdSsiMutex::UnLock().

Referenced by ~XrdSsiMutexMon(), and XrdSsiFileReq::Finalize().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

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