Create a hash table copied from original using basicAllocator.
Synopsis
Declared in <bslstl_hashtable.h>
HashTable(
HashTable const& original,
ALLOCATOR const& basicAllocator);
Description
Create a hash‐table having the same value (and maxLoadFactor) as the specified original object that uses the specified basicAllocator to supply memory. Use a copy of original.hasher() and a copy of original.comparator() to organize elements in this hash‐table. This method requires that the ValueType defined by the (template parameter) type KEY_CONFIG be move‐insertable into this hash‐table. Note that this hash‐table may have a different numBuckets than original, and a correspondingly different loadFactor, as long as maxLoadFactor is not exceeded.
Parameters
Name |
Description |
original |
hash table to copy |
basicAllocator |
allocator used to supply memory |
Created with MrDocs