public final class StoreSupport
extends java.lang.Object
Store
implementations.Modifier and Type | Method and Description |
---|---|
static Store.Provider |
selectStoreProvider(ServiceProvider<Service> serviceProvider,
java.util.Set<ResourceType<?>> resourceTypes,
java.util.Collection<ServiceConfiguration<?,?>> serviceConfigs)
Chooses a
Store.Provider from those
available through the ServiceLocator that best supports the resource types and
service configurations provided. |
static Store.Provider |
selectWrapperStoreProvider(ServiceProvider<Service> serviceProvider,
java.util.Collection<ServiceConfiguration<?,?>> serviceConfigs) |
public static Store.Provider selectWrapperStoreProvider(ServiceProvider<Service> serviceProvider, java.util.Collection<ServiceConfiguration<?,?>> serviceConfigs)
public static Store.Provider selectStoreProvider(ServiceProvider<Service> serviceProvider, java.util.Set<ResourceType<?>> resourceTypes, java.util.Collection<ServiceConfiguration<?,?>> serviceConfigs)
Store.Provider
from those
available through the ServiceLocator
that best supports the resource types and
service configurations provided. This method relies on the
Store.Provider.rank
method in making the
selection.serviceProvider
- the ServiceProvider
instance to useresourceTypes
- the set of ResourceType
s that must be supported by the providerserviceConfigs
- the collection of ServiceConfiguration
s used to influence the
selectionnull
Store.Provider
implementation chosenjava.lang.IllegalStateException
- if no suitable Store.Provider
is available or if
multiple Store.Provider
implementations return the same top ranking