Back to index

lightning-sunbird  0.9+nobinonly
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Private Attributes
nsIDHashKey Class Reference

hashkey wrapper using nsID KeyType More...

#include <nsHashKeys.h>

Inheritance diagram for nsIDHashKey:
Inheritance graph
Collaboration diagram for nsIDHashKey:
Collaboration graph

List of all members.

Public Types

typedef const nsIDKeyType
typedef const nsIDKeyTypePointer

Public Member Functions

 nsIDHashKey (const nsID *inID)
 nsIDHashKey (const nsIDHashKey &toCopy)
 ~nsIDHashKey ()
KeyType GetKey () const
KeyTypePointer GetKeyPointer () const
PRBool KeyEquals (KeyTypePointer aKey) const

Static Public Member Functions

static KeyTypePointer KeyToPointer (KeyType aKey)
static PLDHashNumber HashKey (KeyTypePointer aKey)

Public Attributes

PLDHashNumber keyHash

Private Attributes

const nsID mID

Detailed Description

hashkey wrapper using nsID KeyType

See also:
nsTHashtable::EntryType for specification

Definition at line 236 of file nsHashKeys.h.

Member Typedef Documentation

Definition at line 239 of file nsHashKeys.h.

Definition at line 240 of file nsHashKeys.h.

Member Enumeration Documentation

anonymous enum

Definition at line 253 of file nsHashKeys.h.

Constructor & Destructor Documentation

nsIDHashKey::nsIDHashKey ( const nsID inID) [inline]

Definition at line 242 of file nsHashKeys.h.

: mID(*inID) { }
nsIDHashKey::nsIDHashKey ( const nsIDHashKey toCopy) [inline]

Definition at line 243 of file nsHashKeys.h.

: mID(toCopy.mID) { }

Definition at line 244 of file nsHashKeys.h.

{ }

Member Function Documentation

KeyType nsIDHashKey::GetKey ( void  ) const [inline]

Definition at line 246 of file nsHashKeys.h.

{ return mID; }

Definition at line 247 of file nsHashKeys.h.

{ return &mID; }

Definition at line 109 of file nsTHashtable.cpp.

  PRUint32 h = id->m0;
  PRUint32 i;

  h = (h>>28) ^ (h<<4) ^ id->m1;
  h = (h>>28) ^ (h<<4) ^ id->m2;

  for (i = 0; i < 8; i++)
    h = (h>>28) ^ (h<<4) ^ id->m3[i];

  return h;

Here is the caller graph for this function:

PRBool nsIDHashKey::KeyEquals ( KeyTypePointer  aKey) const [inline]

Definition at line 249 of file nsHashKeys.h.

{ return aKey->Equals(mID); }

Here is the call graph for this function:

static KeyTypePointer nsIDHashKey::KeyToPointer ( KeyType  aKey) [inline, static]

Definition at line 251 of file nsHashKeys.h.

{ return &aKey; }

Member Data Documentation

Definition at line 113 of file pldhash.h.

Definition at line 256 of file nsHashKeys.h.

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