XRootD
XrdOucStack< T > Class Template Reference

#include <XrdOucChain.hh>

+ Collaboration diagram for XrdOucStack< T >:

Public Member Functions

 XrdOucStack ()
 
 ~XrdOucStack ()
 
int isEmpty ()
 
T * Pop ()
 
void Push (XrdOucQSItem< T > *item)
 

Detailed Description

template<class T>
class XrdOucStack< T >

Definition at line 44 of file XrdOucChain.hh.

Constructor & Destructor Documentation

◆ XrdOucStack()

template<class T >
XrdOucStack< T >::XrdOucStack ( )
inline

Definition at line 59 of file XrdOucChain.hh.

59 {anchor = 0;}

◆ ~XrdOucStack()

template<class T >
XrdOucStack< T >::~XrdOucStack ( )
inline

Definition at line 60 of file XrdOucChain.hh.

60 {}

Member Function Documentation

◆ isEmpty()

template<class T >
int XrdOucStack< T >::isEmpty ( )
inline

Definition at line 48 of file XrdOucChain.hh.

48 {return anchor == 0;}

◆ Pop()

template<class T >
T* XrdOucStack< T >::Pop ( )
inline

Definition at line 50 of file XrdOucChain.hh.

50  {XrdOucQSItem<T> *cp;
51  if (!(cp = anchor)) return (T *)0;
52  anchor = anchor->nextelem;
53  cp->nextelem = 0;
54  return cp->dataitem;
55  }
XrdOucQSItem< T > * nextelem
Definition: XrdOucChain.hh:37

References XrdOucQSItem< T >::dataitem, and XrdOucQSItem< T >::nextelem.

Referenced by XrdNetBufferQ::~XrdNetBufferQ(), and XrdNetBufferQ::Alloc().

+ Here is the caller graph for this function:

◆ Push()

template<class T >
void XrdOucStack< T >::Push ( XrdOucQSItem< T > *  item)
inline

Definition at line 57 of file XrdOucChain.hh.

57 {item->nextelem = anchor; anchor = item;}

References XrdOucQSItem< T >::nextelem.

Referenced by XrdNetBufferQ::Recycle().

+ Here is the caller graph for this function:

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