|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
@Contract public interface ArchiveHandler
ArchiveHandlers are handling certain archive type. An archive has a unique type which is usually defines how classes and resources are loaded from the archive. ArchiveHandler should be stateless objects although the implementations of this contract can control that using the scope element of the @Service annotation.
| Method Summary | |
|---|---|
void |
expand(ReadableArchive source,
WritableArchive target,
DeploymentContext context)
Prepares the jar file to a format the ApplicationContainer is expecting. |
java.lang.String |
getArchiveType()
|
java.lang.ClassLoader |
getClassLoader(java.lang.ClassLoader parent,
DeploymentContext context)
Creates a classloader that can load code from inside the archive. |
java.lang.String |
getDefaultApplicationName(ReadableArchive archive)
Returns the default name by which the specified archive can be identified. |
java.lang.String |
getDefaultApplicationName(ReadableArchive archive,
DeploymentContext context)
|
java.util.jar.Manifest |
getManifest(ReadableArchive archive)
Returns the manifest file for this archive, this file is usually located at the META-INF/MANIFEST location, however, certain archive type can change this default location or use another mean of expressing manifest information. |
java.lang.String |
getVersionIdentifier(ReadableArchive archive)
Returns the version identifier by which the specified archive can be deployed. |
boolean |
handles(ReadableArchive archive)
Returns true if this handler understands the specified archive and can process it. |
| Method Detail |
|---|
java.lang.String getArchiveType()
java.lang.String getDefaultApplicationName(ReadableArchive archive)
The default name is used, for example, during deployment if no name was specified explicitly as part of the deployment request.
archive - the archive for which to provide the default name
java.lang.String getDefaultApplicationName(ReadableArchive archive,
DeploymentContext context)
java.lang.String getVersionIdentifier(ReadableArchive archive)
The version identifier is used during deployment if no version identifier
was specified null must be returned
archive - the archive for which to provide the version identifier
null
boolean handles(ReadableArchive archive)
throws java.io.IOException
java.io.IOException - The implementation of this method is expected to interact with
the given archive, and if methods on ReadableArchive
throws an IOException, it can be simply tunneled to the caller.
java.lang.ClassLoader getClassLoader(java.lang.ClassLoader parent,
DeploymentContext context)
parent - The newly created classloader to be returned must eventually delegate to this classloader.
(This classloader is capable of resolving APIs and other things that the containercontext -
void expand(ReadableArchive source,
WritableArchive target,
DeploymentContext context)
throws java.io.IOException
source - of the expandingtarget - of the expandingcontext -
java.io.IOException
java.util.jar.Manifest getManifest(ReadableArchive archive)
throws java.io.IOException
archive - file
java.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||