#include <XrdXrootdFile.hh>
Definition at line 44 of file XrdXrootdFile.hh.
◆ XrdXrootdFileHP()
XrdXrootdFileHP::XrdXrootdFileHP |
( |
int | rsv = 2 | ) |
|
|
inline |
Definition at line 76 of file XrdXrootdFile.hh.
76 : refs(1), noMore(false)
77 {fhAvail.reserve(rsv);}
◆ Avail()
void XrdXrootdFileHP::Avail |
( |
int | fHandle | ) |
|
|
inline |
Definition at line 48 of file XrdXrootdFile.hh.
48 {fhMutex.Lock();
49 bool done = (1 == refs--);
50 if (noMore)
51 {fhMutex.UnLock();
52 if (done) delete this;
53 } else {
54 fhAvail.push_back(fHandle);
55 fhMutex.UnLock();
56 }
57 }
◆ Delete()
void XrdXrootdFileHP::Delete |
( |
| ) |
|
|
inline |
Definition at line 59 of file XrdXrootdFile.hh.
59 {fhMutex.Lock();
60 if (!refs) {fhMutex.UnLock(); delete this;}
61 else {noMore = true; fhMutex.UnLock();}
62 }
◆ Get()
int XrdXrootdFileHP::Get |
( |
| ) |
|
|
inline |
Definition at line 64 of file XrdXrootdFile.hh.
64 {int fh;
65 fhMutex.Lock();
66 if (fhAvail.empty()) fh = -1;
67 else {fh = fhAvail.back();
68 fhAvail.pop_back();
69 }
70 fhMutex.UnLock();
71 return fh;
72 }
◆ Ref()
void XrdXrootdFileHP::Ref |
( |
| ) |
|
|
inline |
The documentation for this class was generated from the following file: