TExMap


class description - source file - inheritance tree

class TExMap : public TObject

    private:
void Expand(Int_t newsize) Int_t FindElement(ULong_t hash, Long_t key) void FixCollisions(Int_t index) Bool_t HighWaterMark() public:
TExMap TExMap(Int_t mapSize = 100) TExMap TExMap(TExMap&) virtual void ~TExMap() void Add(ULong_t hash, Long_t key, Long_t value) void Add(Long_t key, Long_t value) Int_t Capacity() TClass* Class() virtual void Delete(Option_t* opt) Int_t GetSize() Long_t GetValue(ULong_t hash, Long_t key) Long_t GetValue(Long_t key) virtual TClass* IsA() void Remove(ULong_t hash, Long_t key) void Remove(Long_t key) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b)

Data Members

private:
TExMap::Assoc_t** fTable Int_t fSize Int_t fTally

Class Description

                                                                      
 TExMap                                                               
                                                                      
 This class stores a (key,value) pair using an external hash.         
 The (key,value) are Long_t's and therefore can contain object        
 pointers or any longs. The map uses an open addressing hashing       
 method (linear probing).                                             
                                                                      


TExMap(Int_t mapSize)
 Create a TExMap.

~TExMap()
 Delete TExMap.

void Add(ULong_t hash, Long_t key, Long_t value)
 Add an (key,value) pair to the table. The key should be unique.

void Delete(Option_t *)
 Delete all entries stored in the TExMap.

Long_t GetValue(ULong_t hash, Long_t key)
 Return the value belonging to specified key and hash value. If key not
 found return 0.

void Remove(ULong_t hash, Long_t key)
 Remove entry with specified key from the TExMap.

Int_t FindElement(ULong_t hash, Long_t key)
 Find an entry with specified hash and key in the TExMap.
 Returns the slot of the key or the next empty slot.

void FixCollisions(Int_t index)
 Rehash the map in case an entry has been removed.

void Expand(Int_t newSize)
 Expand the TExMap.



Inline Functions


             Bool_t HighWaterMark()
               void Add(Long_t key, Long_t value)
              Int_t Capacity()
              Int_t GetSize()
             Long_t GetValue(Long_t key)
               void Remove(Long_t key)
            TClass* Class()
            TClass* IsA()
               void ShowMembers(TMemberInspector& insp, char* parent)
               void Streamer(TBuffer& b)
             TExMap TExMap(TExMap&)


Author: Fons Rademakers 26/05/99
Last update: 2.22/08 07/07/99 13.26.14 by Fons Rademakers
Copyright (c) 1995-1999, The ROOT System, All rights reserved. *


ROOT page - Class index - Top of the page

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.