public class QueryBackendRegistry
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
java.lang.Iterable<java.util.Map.Entry<java.lang.Class<? extends IQueryBackend>,IQueryBackendFactory>> |
getAllKnownFactories()
Returns all known factory instances in an iterable object
|
java.lang.Class<? extends IQueryBackend> |
getDefaultBackendClass() |
java.lang.Class<? extends IQueryBackend> |
getDefaultCachingBackendClass() |
IQueryBackendFactory |
getFactory(java.lang.Class<? extends IQueryBackend> backend)
Returns a factory for the selected backend class.
|
static QueryBackendRegistry |
getInstance()
Returns the singleton instanceof of the backend registry
|
void |
registerQueryBackendFactory(java.lang.Class<? extends IQueryBackend> backend,
IQueryBackendFactory factory)
Registers a factory instance for a backend class.
|
void |
registerQueryBackendFactoryUnchecked(java.lang.Class<? extends IQueryBackend> backend,
IQueryBackendFactory factory)
Registers a factory instance for a backend class if no class is already registered
|
public static QueryBackendRegistry getInstance()
public java.lang.Class<? extends IQueryBackend> getDefaultBackendClass()
public java.lang.Class<? extends IQueryBackend> getDefaultCachingBackendClass()
public void registerQueryBackendFactory(java.lang.Class<? extends IQueryBackend> backend, IQueryBackendFactory factory)
java.lang.IllegalStateException
- if a factory is already registered for the selected backendpublic void registerQueryBackendFactoryUnchecked(java.lang.Class<? extends IQueryBackend> backend, IQueryBackendFactory factory)
java.lang.IllegalStateException
- if a factory is already registered for the selected backendpublic IQueryBackendFactory getFactory(java.lang.Class<? extends IQueryBackend> backend)
backend
- java.lang.IllegalStateException
- if no corresponding backend is registered into the factorypublic java.lang.Iterable<java.util.Map.Entry<java.lang.Class<? extends IQueryBackend>,IQueryBackendFactory>> getAllKnownFactories()