public interface RhqAgentPluginDescriptorContainer<T extends org.jboss.shrinkwrap.api.Archive<T>>
| Modifier and Type | Method and Description |
|---|---|
List<org.jboss.shrinkwrap.api.Archive<?>> |
getRequiredPlugins()
Returns the list of archives containing the plugins that this plugin is
dependent on.
|
org.jboss.shrinkwrap.api.ArchivePath |
getRequiredPluginsPath()
The RHQ plugin archive can carry along another set of plugins that it is
dependent upon (these can be determined for example by using
withRequiredPluginsFrom(Collection)
method). |
T |
setPluginDescriptor(org.jboss.shrinkwrap.api.asset.Asset asset)
Sets the plugin descriptor using the provided asset.
|
T |
setPluginDescriptor(File file)
Sets the plugin descriptor using the given file.
|
T |
setPluginDescriptor(String resourceName)
Sets the plugin descriptor using the resource name.
|
T |
setPluginDescriptor(URL url)
Sets the plugin descriptor using the provided URL.
|
T |
setPluginDescriptorFromTemplate(String resourceName,
Map<String,String> replacementValues)
Sets the plugin descriptor using the plugin descriptor template resource, making
a copy of that resource and replacing templatized variables in that file with
replacement values that are passed into this method.
|
T |
withRequiredPluginsFrom(org.jboss.shrinkwrap.api.Archive<?>... archives)
An overloaded version of
withRequiredPluginsFrom(Collection) |
T |
withRequiredPluginsFrom(Collection<? extends org.jboss.shrinkwrap.api.Archive<?>> archives)
Using this method, one can supply a single RHQ plugin together with
the plugins that the plugin is dependent upon.
|
org.jboss.shrinkwrap.api.ArchivePath getRequiredPluginsPath()
withRequiredPluginsFrom(Collection)
method).
These are internally stored under the path returned from this method. When creating a JAR archive file out of the shrinkwrap representation of the archive, it is important to excelude this path from the resulting JAR.
You can do this by casting the archive to a FilteredView for example.
withRequiredPluginsFrom(Collection) method.T setPluginDescriptorFromTemplate(String resourceName, Map<String,String> replacementValues) throws IllegalArgumentException
ClassLoader is used to obtain the plugin descriptor template resource, but
it is assumed to be a file on the file system.resourceName - the name of the plugin descriptor template resource as accessible by the class loaderreplacementValues - map with keys of template replacement variable names with their replacement valuesIllegalArgumentException - if resourceName or replacementValues is nullT setPluginDescriptor(String resourceName) throws IllegalArgumentException
ClassLoader is
used to obtain the resource.resourceName - the name of the resource as accessible by the class loaderIllegalArgumentException - if resourceName is nullT setPluginDescriptor(File file) throws IllegalArgumentException
file - the plugin descriptor fileIllegalArgumentException - if file is null or not readableT setPluginDescriptor(URL url) throws IllegalArgumentException
url - the URL to obtain the plugin descriptor fromIllegalArgumentException - if url is nullT setPluginDescriptor(org.jboss.shrinkwrap.api.asset.Asset asset) throws IllegalArgumentException
asset - the asset representing the plugin descriptorIllegalArgumentException - if asset is nullT withRequiredPluginsFrom(Collection<? extends org.jboss.shrinkwrap.api.Archive<?>> archives) throws IllegalArgumentException
This method is only effective after the plugin descriptor has been set using
one of the setPluginDescriptor methods (or by placing the plugin
descriptor directly into "META-INF/rhq-plugin.xml" manually).
archives - the archives to look for the required RHQ plugins inIllegalArgumentException - if the collection is nullT withRequiredPluginsFrom(org.jboss.shrinkwrap.api.Archive<?>... archives) throws IllegalArgumentException
withRequiredPluginsFrom(Collection)IllegalArgumentExceptionList<org.jboss.shrinkwrap.api.Archive<?>> getRequiredPlugins()
withRequiredPluginsFrom(Collection) call.Copyright © 2008-2013 Red Hat, Inc.. All Rights Reserved.