Smart descriptor - closes the descriptor on destruction.
More...
#include <XrdClUtils.hh>
Smart descriptor - closes the descriptor on destruction.
Definition at line 294 of file XrdClUtils.hh.
◆ ScopedDescriptor()
XrdCl::ScopedDescriptor::ScopedDescriptor |
( |
int |
descriptor | ) |
|
|
inline |
Constructor.
Definition at line 300 of file XrdClUtils.hh.
300: pDescriptor( descriptor ) {}
◆ ~ScopedDescriptor()
XrdCl::ScopedDescriptor::~ScopedDescriptor |
( |
| ) |
|
|
inline |
◆ GetDescriptor()
int XrdCl::ScopedDescriptor::GetDescriptor |
( |
| ) |
|
|
inline |
Get the descriptor.
Definition at line 320 of file XrdClUtils.hh.
321 {
322 return pDescriptor;
323 }
◆ Release()
int XrdCl::ScopedDescriptor::Release |
( |
| ) |
|
|
inline |
Release the descriptor being held.
Definition at line 310 of file XrdClUtils.hh.
311 {
312 int desc = pDescriptor;
313 pDescriptor = -1;
314 return desc;
315 }
The documentation for this class was generated from the following file: