/** * Randomly selects a new hash function and reorganizes this SymbolTable * in order to more evenly distribute its entries across the table. This * method is called automatically when the number keys in one of the * SymbolTable's buckets exceeds the given collision threshold. */ protected void rebalance() { if (fHashMultipliers == null) { fHashMultipliers = new int[MULTIPLIERS_SIZE]; } PrimeNumberSequenceGenerator.generateSequence(fHashMultipliers); rehashCommon(fBuckets.length); }
/** * Randomly selects a new hash function and reorganizes this SymbolHash * in order to more evenly distribute its entries across the table. This * method is called automatically when the number keys in one of the * SymbolHash's buckets exceeds MAX_HASH_COLLISIONS. */ protected void rebalance() { if (fHashMultipliers == null) { fHashMultipliers = new int[MULTIPLIERS_SIZE]; } PrimeNumberSequenceGenerator.generateSequence(fHashMultipliers); rehashCommon(fBuckets.length); }
/** * Randomly selects a new hash function and reorganizes the table view * in order to more evenly distribute its entries. This method is called * automatically when the number of attributes in one bucket exceeds * MAX_HASH_COLLISIONS. */ private void rebalanceTableView(final int count) { if (fHashMultipliers == null) { fHashMultipliers = new int[MULTIPLIERS_SIZE + 1]; } PrimeNumberSequenceGenerator.generateSequence(fHashMultipliers); prepareAndPopulateTableView(count); }
/** * Randomly selects a new hash function and reorganizes this SymbolTable * in order to more evenly distribute its entries across the table. This * method is called automatically when the number keys in one of the * SymbolTable's buckets exceeds the given collision threshold. */ protected void rebalance() { if (fHashMultipliers == null) { fHashMultipliers = new int[MULTIPLIERS_SIZE]; } PrimeNumberSequenceGenerator.generateSequence(fHashMultipliers); rehashCommon(fBuckets.length); }
/** * Randomly selects a new hash function and reorganizes the table view * in order to more evenly distribute its entries. This method is called * automatically when the number of attributes in one bucket exceeds * MAX_HASH_COLLISIONS. */ private void rebalanceTableViewNS(final int count) { if (fHashMultipliers == null) { fHashMultipliers = new int[MULTIPLIERS_SIZE + 1]; } PrimeNumberSequenceGenerator.generateSequence(fHashMultipliers); prepareAndPopulateTableViewNS(count); }