@Service @PerLookup public class ApplicationArchivist extends Archivist<Application>
annotationProcessingRequested, APPCLIENT_EXTENSION, APPLICATION_EXTENSION, classLoader, confDDFiles, CONNECTOR_EXTENSION, descriptor, EJB_EXTENSION, extensionsArchivists, habitat, handleRuntimeInfo, locator, logger, manifest, MANIFEST_VERSION_VALUE, path, standardDD, UPLOAD_EXTENSION, WEB_EXTENSION, WEB_FRAGMENT_EXTENSION
Constructor and Description |
---|
ApplicationArchivist() |
Modifier and Type | Method and Description |
---|---|
void |
copyInto(Application a,
ReadableArchive source,
WritableArchive target)
Copy this archivist to a new abstract archive
|
void |
copyInto(Application a,
ReadableArchive source,
WritableArchive target,
boolean overwriteManifest)
Copy this archivist to a new abstract archive
|
void |
copyInto(ReadableArchive source,
WritableArchive target)
Copy this archivist to a new abstract archive
|
Application |
createApplication(ReadableArchive archive,
boolean directory)
This method creates a top level Application object for an ear.
|
protected String |
getArchiveExtension() |
List<ConfigurationDeploymentDescriptorFile> |
getConfigurationDDFiles() |
Application |
getDefaultBundleDescriptor() |
ArchiveType |
getModuleType() |
DeploymentDescriptorFile |
getStandardDDFile() |
Application |
open(ReadableArchive appArchive)
open a new application archive file, read all the deployment descriptors
|
Application |
openWith(Application application,
ReadableArchive archive) |
boolean |
performOptionalPkgDependenciesCheck(ReadableArchive archive)
Perform Optional packages dependencies checking on an archive
|
protected boolean |
postHandles(ReadableArchive abstractArchive)
This method will be invoked if and only if the following is true: 1.
|
boolean |
readModulesDescriptors(Application app,
ReadableArchive appArchive)
read the modules deployment descriptor from this application object using the passed archive
|
void |
readRuntimeDeploymentDescriptor(ReadableArchive archive,
Application descriptor)
Read the runtime deployment descriptors (can contained in one or many file) set the corresponding information in the
passed descriptor.
|
void |
validate(ClassLoader aClassLoader)
validates the DOL Objects associated with this archivist, usually it requires that a class loader being set on this
archivist or passed as a parameter
|
protected void |
writeContents(ReadableArchive in,
WritableArchive out)
writes the content of an archive to a JarFile
|
addFileToArchive, copyAnEntry, copyExtraElements, copyInto, copyInto, copyInto, copyInto, copyJarElements, copyStandardDeploymentDescriptors, createModuleDescriptor, getAllWebservicesDeploymentDescriptorPaths, getAnnotationErrorHandler, getClassLoader, getClassPath, getDeploymentDescriptorPath, getDescriptor, getExtensionArchivists, getLibraries, getListOfFilesToSkip, getManifest, getPath, getRuntimeDeploymentDescriptorPath, getRuntimeXMLValidation, getRuntimeXMLValidationLevel, getScanner, getTempFile, getTempFile, getUniqueEntryFilenameFor, getXMLValidation, getXMLValidationLevel, handles, hasRuntimeDeploymentDescriptor, hasStandardDeploymentDescriptor, initializeContext, isAnnotationProcessingRequested, isHandlingRuntimeInfo, isProcessAnnotation, open, open, open, open, open, postAnnotationProcess, postOpen, postRuntimeDDsRead, postStandardDDsRead, postValidate, printDescriptor, processAnnotations, processAnnotations, readAnnotations, readAnnotations, readMetaInfo, readRuntimeDeploymentDescriptor, readStandardDeploymentDescriptor, renameTmp, setAnnotationErrorHandler, setAnnotationProcessingRequested, setArchiveUri, setClassLoader, setClassPath, setDescriptor, setExtensionArchivists, setHandleRuntimeInfo, setManifest, setModuleDescriptor, setRuntimeXMLValidation, setRuntimeXMLValidationLevel, setXMLValidation, setXMLValidationLevel, write, write, write, write, writeContents, writeContents, writeDeploymentDescriptors, writeExtensionDeploymentDescriptors, writeRuntimeDeploymentDescriptors, writeStandardDeploymentDescriptors
public ArchiveType getModuleType()
getModuleType
in class Archivist<Application>
protected void writeContents(ReadableArchive in, WritableArchive out) throws IOException
writeContents
in class Archivist<Application>
in
- the descriptors to use for writingout
- the output stream to write toIOException
public Application getDefaultBundleDescriptor()
getDefaultBundleDescriptor
in class Archivist<Application>
public Application open(ReadableArchive appArchive) throws IOException, SAXParseException
open
in class Archivist<Application>
appArchive
- the file path for the J2EE Application archiveIOException
SAXParseException
public Application openWith(Application application, ReadableArchive archive) throws IOException, SAXParseException
openWith
in class Archivist<Application>
IOException
SAXParseException
public Application createApplication(ReadableArchive archive, boolean directory) throws IOException, SAXParseException
archive
- the archive for the applicationdirectory
- whether the application is packaged as a directoryIOException
SAXParseException
public boolean readModulesDescriptors(Application app, ReadableArchive appArchive) throws IOException, SAXParseException
app
- application containing the list of modules.appArchive
- containing the sub modules files.IOException
SAXParseException
public void readRuntimeDeploymentDescriptor(ReadableArchive archive, Application descriptor) throws IOException, SAXParseException
readRuntimeDeploymentDescriptor
in class Archivist<Application>
archive
- the input archivedescriptor
- the initialized deployment descriptorIOException
SAXParseException
public void validate(ClassLoader aClassLoader)
validate
in class Archivist<Application>
public DeploymentDescriptorFile getStandardDDFile()
getStandardDDFile
in class Archivist<Application>
public List<ConfigurationDeploymentDescriptorFile> getConfigurationDDFiles()
getConfigurationDDFiles
in class Archivist<Application>
public boolean performOptionalPkgDependenciesCheck(ReadableArchive archive) throws IOException
performOptionalPkgDependenciesCheck
in class Archivist<Application>
IOException
public void copyInto(ReadableArchive source, WritableArchive target) throws IOException
copyInto
in class Archivist<Application>
source
- the archive to copy fromtarget
- the new archive to use to copy our contents intoIOException
public void copyInto(Application a, ReadableArchive source, WritableArchive target) throws IOException
a
- the deployment descriptor for an applicationsource
- the source archivetarget
- the target archiveIOException
public void copyInto(Application a, ReadableArchive source, WritableArchive target, boolean overwriteManifest) throws IOException
a
- the deployment descriptor for an applicationsource
- the source archivetarget
- the target archiveoverwriteManifest
- if true, the manifest in source archive overwrites the one in targetIOException
protected boolean postHandles(ReadableArchive abstractArchive) throws IOException
Note that we will only venture a guess for case 1. JSR88 deployment of an application (ear) using InputStream without any deployment descriptor will NOT be supported at this time.
postHandles
in class Archivist<Application>
IOException
protected String getArchiveExtension()
getArchiveExtension
in class Archivist<Application>
Copyright © 2018. All rights reserved.