Module org.apache.arrow.vector
Class DictionaryProvider.MapDictionaryProvider
java.lang.Object
org.apache.arrow.vector.dictionary.DictionaryProvider.MapDictionaryProvider
- All Implemented Interfaces:
AutoCloseable,DictionaryProvider
- Enclosing interface:
- DictionaryProvider
public static class DictionaryProvider.MapDictionaryProvider
extends Object
implements AutoCloseable, DictionaryProvider
Implementation of
DictionaryProvider that is backed by a hash-map.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.arrow.vector.dictionary.DictionaryProvider
DictionaryProvider.MapDictionaryProvider -
Constructor Summary
ConstructorsConstructorDescriptionMapDictionaryProvider(Dictionary... dictionaries) Constructs a new instance from the given dictionaries. -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidcopyStructureFrom(DictionaryProvider other, BufferAllocator allocator) Initialize the map structure from another provider, but with empty vectors.Get all dictionary IDs.lookup(long id) Return the dictionary for the given ID.voidput(Dictionary dictionary)
-
Constructor Details
-
MapDictionaryProvider
Constructs a new instance from the given dictionaries.
-
-
Method Details
-
copyStructureFrom
Initialize the map structure from another provider, but with empty vectors.- Parameters:
other- theDictionaryProviderto copy the ids and fields fromallocator- allocator to create the empty vectors
-
put
-
getDictionaryIds
Description copied from interface:DictionaryProviderGet all dictionary IDs.- Specified by:
getDictionaryIdsin interfaceDictionaryProvider
-
lookup
Description copied from interface:DictionaryProviderReturn the dictionary for the given ID.- Specified by:
lookupin interfaceDictionaryProvider
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-