Exemple #1
0
		// Note: hashsize should be prime near (maxentries*10)
		public Int64HT(int maxentries, int hashsize, int maxvalues)
		{
			this.maxvalues = maxvalues;
			dirtyslots = new List<int>(maxentries);
			slots = new Int64HTSlot[hashsize];
			for (int hi = 0; hi != slots.Length; hi++)
			{
				slots[hi] = new Int64HTSlot();
				if (maxvalues > 0)
				{
					slots[hi].values = new Int64[maxvalues];
				}
			}
		}
Exemple #2
0
 // Note: hashsize should be prime near (maxentries*10)
 public Int64HT(int maxentries, int hashsize, int maxvalues)
 {
     this.maxvalues = maxvalues;
     dirtyslots     = new List <int>(maxentries);
     slots          = new Int64HTSlot[hashsize];
     for (int hi = 0; hi != slots.Length; hi++)
     {
         slots[hi] = new Int64HTSlot();
         if (maxvalues > 0)
         {
             slots[hi].values = new Int64[maxvalues];
         }
     }
 }