V - the dictionary vector type.public class HashTableBasedDictionaryBuilder<V extends ElementAddressableVector> extends Object implements DictionaryBuilder<V>
| Constructor and Description |
|---|
HashTableBasedDictionaryBuilder(V dictionary)
Constructs a hash table based dictionary builder.
|
HashTableBasedDictionaryBuilder(V dictionary,
boolean encodeNull)
Constructs a hash table based dictionary builder.
|
HashTableBasedDictionaryBuilder(V dictionary,
boolean encodeNull,
ArrowBufHasher hasher)
Constructs a hash table based dictionary builder.
|
| Modifier and Type | Method and Description |
|---|---|
int |
addValue(V targetVector,
int targetIndex)
Try to add an element from the target vector to the dictionary.
|
int |
addValues(V targetVector)
Try to add all values from the target vector to the dictionary.
|
V |
getDictionary()
Gets the dictionary built.
|
public HashTableBasedDictionaryBuilder(V dictionary)
dictionary - the dictionary to populate.public HashTableBasedDictionaryBuilder(V dictionary, boolean encodeNull)
dictionary - the dictionary to populate.encodeNull - if null values should be added to the dictionary.public HashTableBasedDictionaryBuilder(V dictionary, boolean encodeNull, ArrowBufHasher hasher)
dictionary - the dictionary to populate.encodeNull - if null values should be added to the dictionary.hasher - the hasher used to compute the hash code.public V getDictionary()
getDictionary in interface DictionaryBuilder<V extends ElementAddressableVector>public int addValues(V targetVector)
addValues in interface DictionaryBuilder<V extends ElementAddressableVector>targetVector - the target vector containing values to probe.public int addValue(V targetVector, int targetIndex)
addValue in interface DictionaryBuilder<V extends ElementAddressableVector>targetVector - the target vector containing new element.targetIndex - the index of the new element in the target vector.Copyright © 2024 The Apache Software Foundation. All rights reserved.