public class RhqAgentPluginArchiveImpl extends org.jboss.shrinkwrap.impl.base.container.ContainerBase<RhqAgentPluginArchive> implements RhqAgentPluginArchive
| Constructor and Description |
|---|
RhqAgentPluginArchiveImpl(org.jboss.shrinkwrap.api.Archive<?> delegate) |
| Modifier and Type | Method and Description |
|---|---|
protected org.jboss.shrinkwrap.api.ArchivePath |
getClassesPath() |
org.jboss.shrinkwrap.api.ArchivePath |
getLibraryPath() |
protected org.jboss.shrinkwrap.api.ArchivePath |
getManifestPath() |
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
RhqAgentPluginDescriptorContainer.withRequiredPluginsFrom(Collection)
method). |
protected org.jboss.shrinkwrap.api.ArchivePath |
getResourcePath() |
RhqAgentPluginArchive |
setPluginDescriptor(org.jboss.shrinkwrap.api.asset.Asset asset)
Sets the plugin descriptor using the provided asset.
|
RhqAgentPluginArchive |
setPluginDescriptor(File file)
Sets the plugin descriptor using the given file.
|
RhqAgentPluginArchive |
setPluginDescriptor(String resourceName)
Sets the plugin descriptor using the resource name.
|
RhqAgentPluginArchive |
setPluginDescriptor(URL url)
Sets the plugin descriptor using the provided URL.
|
RhqAgentPluginArchive |
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.
|
RhqAgentPluginArchive |
withRequiredPluginsFrom(org.jboss.shrinkwrap.api.Archive<?>... archives)
An overloaded version of
RhqAgentPluginDescriptorContainer.withRequiredPluginsFrom(Collection) |
RhqAgentPluginArchive |
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.
|
add, add, add, add, add, add, add, addAsDirectories, addAsDirectories, addAsDirectory, addAsDirectory, addAsLibraries, addAsLibraries, addAsLibraries, addAsLibraries, addAsLibraries, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResources, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResources, addAsServiceProvider, addAsServiceProvider, addAsServiceProviderAndClasses, addClass, addClass, addClass, addClasses, addDefaultPackage, addManifest, addPackage, addPackage, addPackages, addPackages, addPackages, addPackages, contains, contains, covarientReturn, delete, delete, equals, get, get, getActualClass, getArchiveFormat, getAsType, getAsType, getAsType, getAsType, getAsType, getAsType, getContent, getContent, getName, hashCode, merge, merge, merge, merge, merge, merge, setManifest, setManifest, setManifest, setManifest, setManifest, toString, toString, toString, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitadd, add, add, add, add, add, add, addAsDirectories, addAsDirectories, addAsDirectory, addAsDirectory, contains, contains, delete, delete, get, get, getAsType, getAsType, getAsType, getAsType, getAsType, getAsType, getContent, getContent, getName, merge, merge, merge, merge, merge, merge, toString, toString, toString, writeToaddAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResource, addAsManifestResources, addAsServiceProvider, addAsServiceProvider, addManifest, setManifest, setManifest, setManifest, setManifest, setManifestaddClass, addClass, addClass, addClasses, addDefaultPackage, addPackage, addPackage, addPackages, addPackages, addPackages, addPackagesaddAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResource, addAsResourcesaddAsLibraries, addAsLibraries, addAsLibraries, addAsLibraries, addAsLibraries, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrary, addAsLibrarypublic RhqAgentPluginArchiveImpl(org.jboss.shrinkwrap.api.Archive<?> delegate)
public org.jboss.shrinkwrap.api.ArchivePath getRequiredPluginsPath()
RhqAgentPluginDescriptorContainerRhqAgentPluginDescriptorContainer.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.
getRequiredPluginsPath in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>RhqAgentPluginDescriptorContainer.withRequiredPluginsFrom(Collection) method.protected org.jboss.shrinkwrap.api.ArchivePath getManifestPath()
getManifestPath in class org.jboss.shrinkwrap.impl.base.container.ContainerBase<RhqAgentPluginArchive>protected org.jboss.shrinkwrap.api.ArchivePath getClassesPath()
getClassesPath in class org.jboss.shrinkwrap.impl.base.container.ContainerBase<RhqAgentPluginArchive>protected org.jboss.shrinkwrap.api.ArchivePath getResourcePath()
getResourcePath in class org.jboss.shrinkwrap.impl.base.container.ContainerBase<RhqAgentPluginArchive>public org.jboss.shrinkwrap.api.ArchivePath getLibraryPath()
getLibraryPath in class org.jboss.shrinkwrap.impl.base.container.ContainerBase<RhqAgentPluginArchive>public RhqAgentPluginArchive setPluginDescriptorFromTemplate(String resourceName, Map<String,String> replacementValues) throws IllegalArgumentException
RhqAgentPluginDescriptorContainerClassLoader is used to obtain the plugin descriptor template resource, but
it is assumed to be a file on the file system.setPluginDescriptorFromTemplate in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>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 nullpublic RhqAgentPluginArchive setPluginDescriptor(String resourceName) throws IllegalArgumentException
RhqAgentPluginDescriptorContainerClassLoader is
used to obtain the resource.setPluginDescriptor in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>resourceName - the name of the resource as accessible by the class loaderIllegalArgumentException - if resourceName is nullpublic RhqAgentPluginArchive setPluginDescriptor(File file) throws IllegalArgumentException
RhqAgentPluginDescriptorContainersetPluginDescriptor in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>file - the plugin descriptor fileIllegalArgumentException - if file is null or not readablepublic RhqAgentPluginArchive setPluginDescriptor(URL url) throws IllegalArgumentException
RhqAgentPluginDescriptorContainersetPluginDescriptor in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>url - the URL to obtain the plugin descriptor fromIllegalArgumentException - if url is nullpublic RhqAgentPluginArchive setPluginDescriptor(org.jboss.shrinkwrap.api.asset.Asset asset) throws IllegalArgumentException
RhqAgentPluginDescriptorContainersetPluginDescriptor in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>asset - the asset representing the plugin descriptorIllegalArgumentException - if asset is nullpublic RhqAgentPluginArchive withRequiredPluginsFrom(Collection<? extends org.jboss.shrinkwrap.api.Archive<?>> archives) throws IllegalArgumentException
RhqAgentPluginDescriptorContainer
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).
withRequiredPluginsFrom in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>archives - the archives to look for the required RHQ plugins inIllegalArgumentException - if the collection is nullpublic RhqAgentPluginArchive withRequiredPluginsFrom(org.jboss.shrinkwrap.api.Archive<?>... archives) throws IllegalArgumentException
RhqAgentPluginDescriptorContainerRhqAgentPluginDescriptorContainer.withRequiredPluginsFrom(Collection)withRequiredPluginsFrom in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>IllegalArgumentExceptionpublic List<org.jboss.shrinkwrap.api.Archive<?>> getRequiredPlugins()
RhqAgentPluginDescriptorContainerRhqAgentPluginDescriptorContainer.withRequiredPluginsFrom(Collection) call.getRequiredPlugins in interface RhqAgentPluginDescriptorContainer<RhqAgentPluginArchive>Copyright © 2008-2013 Red Hat, Inc.. All Rights Reserved.