public class JarModule extends AbstractEarModule
EarModule
implementation for a non J2EE module such as third party libraries.
Such module is not incorporated in the generated application.xml
but some application servers support it. To include it in the generated
deployment descriptor anyway, set the includeInApplicationXml
boolean flag.
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_ARTIFACT_TYPE
Default type of the artifact of a non Java EE module such as third party library.
|
ALT_DD, altDeploymentDescriptor, bundleDir, bundleFileName, classPathItem, earExecutionContext, excluded, JAVA_MODULE, libDirectory, MODULE_ELEMENT, type, unpack
Constructor and Description |
---|
JarModule()
Create an instance.
|
JarModule(org.apache.maven.artifact.Artifact a,
String defaultLibBundleDir,
Boolean includeInApplicationXml) |
Modifier and Type | Method and Description |
---|---|
void |
appendModule(org.codehaus.plexus.util.xml.XMLWriter writer,
String version,
Boolean generateId)
Appends the
XML representation of this module. |
boolean |
changeManifestClasspath() |
void |
resolveArtifact(Set<org.apache.maven.artifact.Artifact> artifacts)
Resolves the
Artifact represented by the module. |
getAltDeploymentDescriptor, getArtifact, getArtifactId, getBundleDir, getBundleFileName, getClassifier, getGroupId, getLibDir, getModuleId, getType, getUri, isClassPathItem, isExcluded, setEarExecutionContext, shouldUnpack, startModuleElement, toString, writeAltDeploymentDescriptor
public static final String DEFAULT_ARTIFACT_TYPE
public void appendModule(org.codehaus.plexus.util.xml.XMLWriter writer, String version, Boolean generateId)
XML
representation of this module.writer
- the writer to useversion
- the version of the application.xml
filegenerateId
- whether an id should be generatedpublic void resolveArtifact(Set<org.apache.maven.artifact.Artifact> artifacts) throws EarPluginException, org.apache.maven.plugin.MojoFailureException
Artifact
represented by the module. Note that the EarExecutionContext
might be used
to customize further the resolution.resolveArtifact
in interface EarModule
resolveArtifact
in class AbstractEarModule
artifacts
- the project's artifactsEarPluginException
- if the artifact could not be resolvedorg.apache.maven.plugin.MojoFailureException
- if an unexpected error occurredpublic boolean changeManifestClasspath()
changeManifestClasspath
in interface EarModule
changeManifestClasspath
in class AbstractEarModule
true
Copyright © 2002–2022 The Apache Software Foundation. All rights reserved.