public class ProviderRegistryImpl extends Object implements ProviderRegistry
Constructor and Description |
---|
ProviderRegistryImpl() |
Modifier and Type | Method and Description |
---|---|
protected Iterable<Class<? extends Provider>> |
enumerateProviderInterfaces(Provider provider)
Enumerates all Provider-derived interfaces in the type hierarchy of the specified Provider class.
|
MetadataProvider |
getMetadataProvider(Class<?> type)
Obtain the first MetadataProvider which handles the gives type.
|
List<MetadataProvider> |
getMetadataProviders()
Obtain list of all registered MetadataProviders
|
PersistenceProvider |
getPersistenceProvider(Class<?> type)
Return the persistence provider for a given type.
|
List<Provider> |
getProviders()
Obtain list of all registered providers.
|
List<Provider> |
getProvidersForType(Class<? extends Provider> providerType)
Obtain list of all registered providers of a given type.
|
protected boolean |
hasDataObjectServiceMethod(Provider provider,
String methodName,
Class[] args)
Determines if the given
Provider has the given method. |
void |
registerProvider(Provider provider)
Register a Provider.
|
boolean |
unregisterProvider(Provider provider)
Unregister a Provider if it exists.
|
public ProviderRegistryImpl()
protected Iterable<Class<? extends Provider>> enumerateProviderInterfaces(Provider provider)
provider
- the Provider class to inspect.public void registerProvider(Provider provider)
registerProvider
in interface ProviderRegistry
provider
- the provider to registerpublic boolean unregisterProvider(Provider provider)
unregisterProvider
in interface ProviderRegistry
provider
- the provider to unregisterpublic List<Provider> getProviders()
getProviders
in interface ProviderRegistry
public List<Provider> getProvidersForType(Class<? extends Provider> providerType)
getProvidersForType
in interface ProviderRegistry
providerType
- the provider typepublic List<MetadataProvider> getMetadataProviders()
getMetadataProviders
in interface ProviderRegistry
public PersistenceProvider getPersistenceProvider(Class<?> type)
getPersistenceProvider
in interface ProviderRegistry
type
- the data object typepublic MetadataProvider getMetadataProvider(Class<?> type)
getMetadataProvider
in interface ProviderRegistry
protected boolean hasDataObjectServiceMethod(Provider provider, String methodName, Class[] args)
Provider
has the given method.provider
- the Provider
to check.methodName
- the method name to check for.args
- the arguments for the method.Copyright © 2005–2015 The Kuali Foundation. All rights reserved.