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