public class ResourceModelSourceService extends PluggableProviderRegistryService<ResourceModelSourceFactory> implements ConfigurableService<ResourceModelSource>, DescribableService, PluggableProviderService<ResourceModelSourceFactory>, JavaClassProviderLoadable<ResourceModelSourceFactory>, ScriptPluginProviderLoadable<ResourceModelSourceFactory>
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
SERVICE_NAME |
frameworkinstanceregistry, registry| Constructor and Description |
|---|
ResourceModelSourceService(Framework framework) |
| Modifier and Type | Method and Description |
|---|---|
<X extends ResourceModelSourceFactory> |
createProviderInstance(java.lang.Class<X> clazz,
java.lang.String name) |
ResourceModelSourceFactory |
createScriptProviderInstance(ScriptPluginProvider provider) |
static java.util.function.Function<ResourceModelSourceFactory,ResourceModelSource> |
factoryConverter(java.util.Properties configuration)
Given input configuration, produce a function to convert from a factory to model source
|
static java.util.function.Function<ResourceModelSourceFactory,ResourceModelSource> |
factoryConverter(Services services,
java.util.Properties configuration)
Given input configuration, produce a function to convert from a factory to model source
|
java.util.List<java.lang.String> |
getBundledProviderNames() |
CloseableProvider<ResourceModelSource> |
getCloseableProviderForConfiguration(java.lang.String type,
java.util.Properties configuration)
Return a provider of type T which can be closed
|
CloseableProvider<ResourceModelSource> |
getCloseableSourceForConfiguration(java.lang.String type,
java.util.Properties configuration) |
CloseableProvider<ResourceModelSource> |
getCloseableSourceForConfiguration(java.lang.String type,
java.util.Properties configuration,
Services services) |
static ResourceModelSourceService |
getInstanceForFramework(Framework framework) |
java.lang.String |
getName() |
ResourceModelSource |
getProviderForConfiguration(java.lang.String type,
java.util.Properties configuration) |
ResourceModelSource |
getSourceForConfiguration(java.lang.String type,
java.util.Properties configuration) |
boolean |
isValidProviderClass(java.lang.Class clazz) |
java.util.List<ProviderIdent> |
listDescribableProviders() |
java.util.List<Description> |
listDescriptions() |
closeableProviderOfType, listProviders, providerOfTypecreateProviderInstanceFromType, hasValidProviderSignatureregisterClass, registerInstanceclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitadaptercloseableProviderOfType, listProviders, providerOfTypecanLoadWithLoader, loadCloseableWithLoader, loadWithLoaderisCacheInstances, registerClass, registerInstance, setCacheInstancespublic static final java.lang.String SERVICE_NAME
public ResourceModelSourceService(Framework framework)
public java.util.List<java.lang.String> getBundledProviderNames()
public java.lang.String getName()
getName in interface FrameworkSupportServicepublic static ResourceModelSourceService getInstanceForFramework(Framework framework)
public ResourceModelSource getSourceForConfiguration(java.lang.String type, java.util.Properties configuration) throws ExecutionServiceException
configuration - configurationtype - provider nameExecutionServiceException - on errorpublic CloseableProvider<ResourceModelSource> getCloseableSourceForConfiguration(java.lang.String type, java.util.Properties configuration) throws ExecutionServiceException
configuration - configurationtype - provider nameExecutionServiceException - on errorpublic CloseableProvider<ResourceModelSource> getCloseableSourceForConfiguration(java.lang.String type, java.util.Properties configuration, Services services) throws ExecutionServiceException
configuration - configurationtype - provider nameExecutionServiceException - on errorpublic static java.util.function.Function<ResourceModelSourceFactory,ResourceModelSource> factoryConverter(java.util.Properties configuration)
configuration - public static java.util.function.Function<ResourceModelSourceFactory,ResourceModelSource> factoryConverter(Services services, java.util.Properties configuration)
configuration - public boolean isValidProviderClass(java.lang.Class clazz)
isValidProviderClass in interface JavaClassProviderLoadable<ResourceModelSourceFactory>clazz - the classpublic <X extends ResourceModelSourceFactory> ResourceModelSourceFactory createProviderInstance(java.lang.Class<X> clazz, java.lang.String name) throws PluginException, ProviderCreationException
createProviderInstance in interface JavaClassProviderLoadable<ResourceModelSourceFactory>X - subtype of Tclazz - the classname - the provider namePluginException - if the plugin has an errorProviderCreationException - if creating the instance has an errorpublic ResourceModelSourceFactory createScriptProviderInstance(ScriptPluginProvider provider) throws PluginException
createScriptProviderInstance in interface ScriptPluginProviderLoadable<ResourceModelSourceFactory>provider - the script plugin providerPluginException - if the plugin has an errorpublic ResourceModelSource getProviderForConfiguration(java.lang.String type, java.util.Properties configuration) throws ExecutionServiceException
getProviderForConfiguration in interface ConfigurableService<ResourceModelSource>type - provider nameconfiguration - configuration propertiesExecutionServiceException - on errorpublic CloseableProvider<ResourceModelSource> getCloseableProviderForConfiguration(java.lang.String type, java.util.Properties configuration) throws ExecutionServiceException
ConfigurableServicegetCloseableProviderForConfiguration in interface ConfigurableService<ResourceModelSource>type - plugin typeconfiguration - configuration propertiesExecutionServiceExceptionpublic java.util.List<Description> listDescriptions()
listDescriptions in interface DescribableServicepublic java.util.List<ProviderIdent> listDescribableProviders()
listDescribableProviders in interface DescribableService