47 _hashMethod(hashMethod)
67 _hashMethod(other._hashMethod),
68 _usedSlots(other._usedSlots),
69 _entries(other._entries),
75 for (i=0 ; i<
_size ; i++) {
110 if (
_arr[slot]->Remove(arg)) {
112 if (
_arr[slot]->GetSize()==0) {
130 for (i=0 ; i<
_size ; i++) {
131 if (i != slot &&
_arr[i] &&
_arr[i]->Remove(arg)) {
133 if (
_arr[i]->GetSize()==0) {
153 for (i=0 ; i<20 ; i++) h[i]=0 ;
155 for (i=0 ; i<
_size ; i++) {
182 if (newSlot == slot) {
230 return elem ? elem->
_arg : 0 ;
247 while ((obj=it.
next())) {
249 if (elem->
_arg == hashArg)
return elem ;
287 for (i=0 ; i<
_size ; i++) {
Double_t avgCollisions() const
Calculate the average number of collisions (table slots with >1 filled entry)
TObject * find(const char *name) const
Return the object with given name from the table.
RooAbsArg * findArg(const RooAbsArg *) const
Return pointer to object with given name in collection.
RooHashTable(Int_t initSize=17, HashMethod hashMethod=Name)
Construct a hash table with given capacity and hash method.
Bool_t replace(const TObject *oldArg, const TObject *newArg, const TObject *oldHashArg=0)
Replace oldArg with newArg in the table.
Bool_t Replace(const TObject *oldArg, const TObject *newArg)
Replace object 'oldArg' in collection with new object 'newArg'.
const TNamed * namePtr() const
RooHashTable implements a hash table for TObjects.
virtual ULong_t Hash() const
Return hash value for this object.
void useNptr(Bool_t flag)
virtual void Add(TObject *arg)
void add(TObject *arg, TObject *hashArg=0)
Add given object to table.
Bool_t TestBit(UInt_t f) const
virtual const char * GetName() const
Returns name of object.
Bool_t remove(TObject *arg, TObject *hashArg=0)
Remove given object from table.
ULong_t Hash(const void *txt, Int_t ntxt)
Calculates hash index from any char string.
virtual ~RooHashTable()
Destructor.
Long_t NextPrime(Long_t x)
TMath Base functions.
RooLinkedList is an collection class for internal use, storing a collection of RooAbsArg pointers in ...
RooFIter fwdIterator() const
TObject * find(const char *name) const
Return pointer to object with given name in collection.
Mother of all ROOT objects.
Short_t Max(Short_t a, Short_t b)
RooLinkedListElem is an link element for the RooLinkedList class.
RooAbsArg * findArg(const RooAbsArg *arg) const
RooSetPair * findSetPair(const RooArgSet *set1, const RooArgSet *set2) const
Return RooSetPair with given pointers in table.
RooAbsArg is the common abstract base class for objects that represent a value (of arbitrary type) an...
RooSetPair is a utility class that stores a pair of RooArgSets.
RooLinkedListElem * findLinkTo(const TObject *arg) const
Return RooLinkedList element link to object 'hashArg'.
ULong_t hash(const TObject *arg) const