NAMD
Public Member Functions | Static Public Member Functions | List of all members
HashPoolAdaptorT< T > Class Template Reference

#include <CompressPsf.h>

Public Member Functions

 HashPoolAdaptorT (const T &v)
 
 HashPoolAdaptorT ()
 
 operator T & ()
 
 operator const T & () const
 
CkHashCode hash (void) const
 
int compare (const HashPoolAdaptorT< T > &t) const
 
T & getVal ()
 
void pup (PUP::er &p)
 

Static Public Member Functions

static CkHashCode staticHash (const void *k, size_t)
 
static int staticCompare (const void *a, const void *b, size_t)
 

Detailed Description

template<class T>
class HashPoolAdaptorT< T >

Definition at line 68 of file CompressPsf.h.

Constructor & Destructor Documentation

template<class T>
HashPoolAdaptorT< T >::HashPoolAdaptorT ( const T &  v)
inline

Definition at line 71 of file CompressPsf.h.

71 :val(v) { }
template<class T>
HashPoolAdaptorT< T >::HashPoolAdaptorT ( )
inline

added to allow pup to do Key k while unPacking

Definition at line 73 of file CompressPsf.h.

73 {}

Member Function Documentation

template<class T>
int HashPoolAdaptorT< T >::compare ( const HashPoolAdaptorT< T > &  t) const
inline

Definition at line 86 of file CompressPsf.h.

86  {
87  return val==t.val;
88  }
template<class T>
T& HashPoolAdaptorT< T >::getVal ( )
inline

Definition at line 94 of file CompressPsf.h.

94 { return val; }
template<class T>
CkHashCode HashPoolAdaptorT< T >::hash ( void  ) const
inline

Definition at line 77 of file CompressPsf.h.

Referenced by HashPool< T >::dump_tables(), and HashPool< T >::lookupCstPool().

77  {
78  const int hash=val.hash();
79  return CkHashFunction_int(&hash,sizeof(int));
80  }
CkHashCode hash(void) const
Definition: CompressPsf.h:77
template<class T>
HashPoolAdaptorT< T >::operator const T & ( ) const
inline

Definition at line 75 of file CompressPsf.h.

75 { return val; }
template<class T>
HashPoolAdaptorT< T >::operator T & ( )
inline

Definition at line 74 of file CompressPsf.h.

74 { return val; }
template<class T>
void HashPoolAdaptorT< T >::pup ( PUP::er &  p)
inline

Definition at line 97 of file CompressPsf.h.

97  {
98  p | *val;
99  }
template<class T>
static int HashPoolAdaptorT< T >::staticCompare ( const void a,
const void b,
size_t   
)
inlinestatic

Definition at line 90 of file CompressPsf.h.

90  {
91  return ((HashPoolAdaptorT<T> *)a)->compare(*(HashPoolAdaptorT<T> *)b);
92  }
template<class T>
static CkHashCode HashPoolAdaptorT< T >::staticHash ( const void k,
size_t   
)
inlinestatic

Definition at line 82 of file CompressPsf.h.

82  {
83  return ((HashPoolAdaptorT<T> *)k)->hash();
84  }

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