XRootD
Loading...
Searching...
No Matches
XrdOfsHanKey Class Reference

#include <XrdOfsHandle.hh>

+ Collaboration diagram for XrdOfsHanKey:

Public Member Functions

 XrdOfsHanKey (const char *key=0, int kln=0)
 
 XrdOfsHanKey (const XrdOfsHanKey &)=default
 
 ~XrdOfsHanKey ()
 
int operator!= (const XrdOfsHanKey &oth)
 
XrdOfsHanKeyoperator= (const XrdOfsHanKey &rhs)
 
int operator== (const XrdOfsHanKey &oth)
 

Public Attributes

unsigned int Hash
 
short Len
 
unsigned int Links
 
const char * Val
 

Detailed Description

Definition at line 46 of file XrdOfsHandle.hh.

Constructor & Destructor Documentation

◆ XrdOfsHanKey() [1/2]

XrdOfsHanKey::XrdOfsHanKey ( const char * key = 0,
int kln = 0 )
inline

Definition at line 71 of file XrdOfsHandle.hh.

72 : Val(key), Links(0), Len(kln)
73 {Hash = (key && kln ?
74 XrdOucCRC::CRC32((const unsigned char *)key,kln) : 0);
75 }
unsigned int Links
unsigned int Hash
const char * Val
static uint32_t CRC32(const unsigned char *data, int count)
Definition XrdOucCRC.cc:171

References XrdOucCRC::CRC32(), and Hash.

+ Here is the call graph for this function:

◆ XrdOfsHanKey() [2/2]

XrdOfsHanKey::XrdOfsHanKey ( const XrdOfsHanKey & )
default

◆ ~XrdOfsHanKey()

XrdOfsHanKey::~XrdOfsHanKey ( )
inline

Definition at line 79 of file XrdOfsHandle.hh.

79{};

Member Function Documentation

◆ operator!=()

int XrdOfsHanKey::operator!= ( const XrdOfsHanKey & oth)
inline

Definition at line 66 of file XrdOfsHandle.hh.

67 {return Hash != oth.Hash || Len != oth.Len
68 || strcmp(Val, oth.Val);
69 }

References Hash, Len, and Val.

◆ operator=()

XrdOfsHanKey & XrdOfsHanKey::operator= ( const XrdOfsHanKey & rhs)
inline

Definition at line 55 of file XrdOfsHandle.hh.

56 {Val = strdup(rhs.Val); Hash = rhs.Hash;
57 Len = rhs.Len;
58 return *this;
59 }

References Hash, Len, and Val.

◆ operator==()

int XrdOfsHanKey::operator== ( const XrdOfsHanKey & oth)
inline

Definition at line 61 of file XrdOfsHandle.hh.

62 {return Hash == oth.Hash && Len == oth.Len
63 && !strcmp(Val, oth.Val);
64 }

References Hash, Len, and Val.

Member Data Documentation

◆ Hash

unsigned int XrdOfsHanKey::Hash

◆ Len

short XrdOfsHanKey::Len

◆ Links

◆ Val


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