IfdKey Class Reference

#include <IfdKey.h>

Inheritance diagram for IfdKey:

IfdIntKey IfdStrKey List of all members.

Public Member Functions

virtual ~IfdKey ()
virtual int operator== (const IfdKey &) const =0
int operator!= (const IfdKey &k) const
virtual void add (const IfdKey &)
int cardinality (void) const
virtual void print (std::ostream &o) const =0
virtual IfdKeyclone (void) const =0
virtual unsigned int hash (void) const

Static Public Member Functions

static unsigned int nHashBuckets (void)

Public Attributes

unsigned int _hashVal

Protected Types

 _nHashBuckets = 1031
 intKey
 strKey
 compositeKey
 typeKey
 odfTypeKey
enum  { _nHashBuckets = 1031 }
enum  keyKind {
  intKey, strKey, compositeKey, typeKey,
  odfTypeKey
}

Protected Member Functions

 IfdKey (keyKind kind)
IfdKey::keyKind getKeyKind (void) const

Protected Attributes

keyKind _myKeyKind
int _myCardinality
union {
   int   intVal
   unsigned int   uintVal
   char *   strVal
}; 

Private Member Functions

virtual void make_vtab (void) const
 IfdKey (const IfdKey &)
IfdKeyoperator= (IfdKey &)

Friends

class IfdIntKey
class IfdStrKey
class IfdTypeKeyIFace
class IfdCompositeKey
class BdbOdfIfdTypeKeyIFace
std::ostreamoperator<< (std::ostream &o, const IfdKey &k)
unsigned ifdKeyHash (const IfdDictKey &k)

Detailed Description

Definition at line 48 of file IfdKey.h.


Member Enumeration Documentation

anonymous enum [protected]

Enumerator:
_nHashBuckets 

Definition at line 86 of file IfdKey.h.

00086 { _nHashBuckets = 1031 }; // .33 msec/ev, not opt

enum IfdKey::keyKind [protected]

Enumerator:
intKey 
strKey 
compositeKey 
typeKey 
odfTypeKey 

Definition at line 88 of file IfdKey.h.


Constructor & Destructor Documentation

IfdKey::~IfdKey (  )  [virtual]

Definition at line 29 of file IfdKey.cxx.

00030 {}

IfdKey::IfdKey ( keyKind  kind  )  [protected]

Definition at line 23 of file IfdKey.cxx.

00024   : _hashVal( 0 )
00025   , _myKeyKind( kind ) 
00026   , _myCardinality( 0 )
00027 {}

IfdKey::IfdKey ( const IfdKey  )  [inline, private]

Definition at line 158 of file IfdKey.h.

00158 { ::abort(); }


Member Function Documentation

void IfdKey::add ( const IfdKey  )  [virtual]

Definition at line 34 of file IfdKey.cxx.

00034                            {
00035   // only makes sense for the composite class.
00036 
00037   assert( 0 );
00038 }

int IfdKey::cardinality ( void   )  const [inline]

Definition at line 166 of file IfdKey.h.

References _myCardinality.

00166                               { 
00167 //*****************************************************************************
00168     return _myCardinality;
00169 }

virtual IfdKey* IfdKey::clone ( void   )  const [pure virtual]

Implemented in IfdIntKey, and IfdStrKey.

IfdKey::keyKind IfdKey::getKeyKind ( void   )  const [inline, protected]

Definition at line 98 of file IfdKey.h.

References _myKeyKind.

Referenced by IfdStrKey::operator<(), IfdStrKey::operator==(), and IfdIntKey::operator==().

00098 { return _myKeyKind; }

virtual unsigned int IfdKey::hash ( void   )  const [inline, virtual]

Definition at line 77 of file IfdKey.h.

References _hashVal.

00078         { return _hashVal;}

void IfdKey::make_vtab ( void   )  const [private, virtual]

Definition at line 41 of file IfdKey.cxx.

00041                               {
00042   // bogus virtual non-inline routine to get vtab emitted.
00043 }

static unsigned int IfdKey::nHashBuckets ( void   )  [inline, static]

Definition at line 82 of file IfdKey.h.

References _nHashBuckets.

00083        { return _nHashBuckets; }

int IfdKey::operator!= ( const IfdKey k  )  const [inline]

Definition at line 182 of file IfdKey.h.

00182                                             {
00183 //*****************************************************************************
00184 
00185     return ! ( *this == k );
00186 }

IfdKey& IfdKey::operator= ( IfdKey  )  [inline, private]

Definition at line 159 of file IfdKey.h.

00159 { if ( this != 0 ) ::abort(); return *this; }

virtual int IfdKey::operator== ( const IfdKey  )  const [pure virtual]

Implemented in IfdIntKey, and IfdStrKey.

virtual void IfdKey::print ( std::ostream o  )  const [pure virtual]

Implemented in IfdIntKey, and IfdStrKey.

Referenced by operator<<().


Friends And Related Function Documentation

friend class BdbOdfIfdTypeKeyIFace [friend]

Definition at line 136 of file IfdKey.h.

friend class IfdCompositeKey [friend]

Definition at line 135 of file IfdKey.h.

friend class IfdIntKey [friend]

Definition at line 132 of file IfdKey.h.

unsigned ifdKeyHash ( const IfdDictKey &  k  )  [friend]

friend class IfdStrKey [friend]

Definition at line 133 of file IfdKey.h.

friend class IfdTypeKeyIFace [friend]

Definition at line 134 of file IfdKey.h.

std::ostream& operator<< ( std::ostream o,
const IfdKey k 
) [friend]


Member Data Documentation

union { ... } [protected]

unsigned int IfdKey::_hashVal

Definition at line 80 of file IfdKey.h.

Referenced by IfdStrKey::clone(), hash(), IfdIntKey::IfdIntKey(), IfdStrKey::IfdStrKey(), and IfdStrKey::operator==().

int IfdKey::_myCardinality [protected]

Definition at line 122 of file IfdKey.h.

Referenced by cardinality().

keyKind IfdKey::_myKeyKind [protected]

Definition at line 116 of file IfdKey.h.

Referenced by getKeyKind().

int IfdKey::intVal [protected]

Definition at line 126 of file IfdKey.h.

Referenced by IfdIntKey::clone(), IfdIntKey::IfdIntKey(), IfdIntKey::operator==(), and IfdIntKey::print().

char* IfdKey::strVal [protected]

Definition at line 128 of file IfdKey.h.

Referenced by IfdStrKey::asString(), IfdStrKey::clone(), IfdStrKey::IfdStrKey(), IfdStrKey::operator<(), IfdStrKey::operator==(), and IfdStrKey::~IfdStrKey().

unsigned int IfdKey::uintVal [protected]

Definition at line 127 of file IfdKey.h.


Generated on Tue Nov 29 23:19:43 2016 for BOSS_7.0.2 by  doxygen 1.4.7