Package com.exasol.adapter
Class AdapterRegistry
- java.lang.Object
-
- com.exasol.adapter.AdapterRegistry
-
public final class AdapterRegistry extends Object
VirtualSchemaAdapters need to be registered in theAdapterRegistryin order to receive requests from the dispatcher.
-
-
Constructor Summary
Constructors Constructor Description AdapterRegistry()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclear()Remove all registered adapters from the registryStringdescribe()Describe the contents of the registryVirtualSchemaAdaptergetAdapterForName(String name)Get the Virtual Schema Adapter registered under the given namestatic AdapterRegistrygetInstance()Get the singleton instance of theAdapterRegistryList<AdapterFactory>getRegisteredAdapterFactories()Get a list of all currently registered Virtual Schema AdaptersbooleanhasAdapterWithName(String name)Check if an adapter with the given name is registeredvoidregisterAdapterFactory(String adapterName, AdapterFactory factory)Register a factory for aVirtualSchemaAdapter
-
-
-
Method Detail
-
getInstance
public static final AdapterRegistry getInstance()
Get the singleton instance of theAdapterRegistry- Returns:
- singleton instance
-
registerAdapterFactory
public void registerAdapterFactory(String adapterName, AdapterFactory factory)
Register a factory for aVirtualSchemaAdapter- Parameters:
factory- factory that can create the adapteradapterName- name of the adapter
-
getRegisteredAdapterFactories
public List<AdapterFactory> getRegisteredAdapterFactories()
Get a list of all currently registered Virtual Schema Adapters- Returns:
- list of adapter factories
-
getAdapterForName
public VirtualSchemaAdapter getAdapterForName(String name)
Get the Virtual Schema Adapter registered under the given name- Parameters:
name- name of the adapter- Returns:
- adapter instance
-
hasAdapterWithName
public boolean hasAdapterWithName(String name)
Check if an adapter with the given name is registered- Parameters:
name- adapter name to be searched for- Returns:
trueif an adapter is registered under that name
-
clear
public void clear()
Remove all registered adapters from the registry
-
describe
public String describe()
Describe the contents of the registry- Returns:
- description
-
-