Modifier and Type | Field and Description |
---|---|
protected static String |
ALT_DD
The alt-dd module.
|
protected String |
altDeploymentDescriptor
The alternate deployment descriptor.
|
protected String |
bundleDir
The bundleDir.
|
protected String |
bundleFileName
The bundleFileName.
|
protected boolean |
classPathItem
If module is considered for inclusion into the Class-Path entry of MANIFEST.mf of other modules.
|
protected EarExecutionContext |
earExecutionContext
|
protected Boolean |
excluded
excluded by default
false . |
protected static String |
JAVA_MODULE
The java module.
|
protected String |
libDirectory
Directory of module which contains libraries packaged into module.
|
protected static String |
MODULE_ELEMENT
The module element.
|
protected String |
type
The type of the artifact
|
protected Boolean |
unpack
unpack
|
Constructor and Description |
---|
AbstractEarModule()
Empty constructor to be used when the module is built based on the configuration.
|
AbstractEarModule(org.apache.maven.artifact.Artifact a)
Creates an ear module from the artifact.
|
Modifier and Type | Method and Description |
---|---|
boolean |
changeManifestClasspath() |
String |
getAltDeploymentDescriptor()
The alt-dd element specifies an optional URI to the post-assembly version of the deployment descriptor file for a
particular Java EE module.
|
org.apache.maven.artifact.Artifact |
getArtifact()
Returns the
Artifact representing this module. |
String |
getArtifactId()
Returns the artifact's Id.
|
String |
getBundleDir()
Returns the bundle directory.
|
String |
getBundleFileName()
Returns the bundle file name.
|
String |
getClassifier()
Returns the artifact's classifier.
|
String |
getGroupId()
Returns the artifact's groupId.
|
String |
getLibDir() |
String |
getModuleId() |
String |
getType()
Returns the type associated to the module.
|
String |
getUri()
Returns the
URI for this module. |
boolean |
isClassPathItem()
If module should be included into the Class-Path entry of MANIFEST.mf.
|
boolean |
isExcluded()
Specify whether this module should be excluded or not.
|
void |
resolveArtifact(Set<org.apache.maven.artifact.Artifact> artifacts)
Resolves the
Artifact represented by the module. |
void |
setEarExecutionContext(EarExecutionContext earExecutionContext) |
Boolean |
shouldUnpack()
Specify whether this module should be unpacked in the EAR archive or not.
|
protected void |
startModuleElement(org.codehaus.plexus.util.xml.XMLWriter writer,
Boolean generateId)
Starts a new
MODULE_ELEMENT on the specified writer, possibly including an id attribute. |
String |
toString() |
protected void |
writeAltDeploymentDescriptor(org.codehaus.plexus.util.xml.XMLWriter writer,
String version)
Writes the alternative deployment descriptor if necessary.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
appendModule
protected static final String MODULE_ELEMENT
protected static final String JAVA_MODULE
protected static final String ALT_DD
protected String type
protected String bundleDir
protected String bundleFileName
protected Boolean excluded
false
.protected Boolean unpack
protected String altDeploymentDescriptor
protected String libDirectory
null
value means that module
doesn't contain any library. Each module type can provide default value for this directory and this option
can be used to override that default value. If module libraries are located at the root of module then use
single slash (/) to configure that in POM. That is, a single slash is treated as an empty string.protected boolean classPathItem
false
value leads to removal of the module from the Class-Path entry. true
value leads to modification of the
reference to the module in the Class-Path entry if such reference exists or leads to adding of the module into
the Class-Path entry if such reference doesn't exist. Removal, modification or adding of the reference in the
Class-Path entry depends on libDirectory property of another module and on skinnyWars / skinnyModules parameters
of EAR Plugin.protected EarExecutionContext earExecutionContext
public AbstractEarModule()
public AbstractEarModule(org.apache.maven.artifact.Artifact a)
a
- the artifactpublic void setEarExecutionContext(EarExecutionContext earExecutionContext)
setEarExecutionContext
in interface EarModule
earExecutionContext
- The execution context.public 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
artifacts
- the project's artifactsEarPluginException
- if the artifact could not be resolvedorg.apache.maven.plugin.MojoFailureException
- if an unexpected error occurredpublic org.apache.maven.artifact.Artifact getArtifact()
EarModule
Artifact
representing this module.
Note that this might return null
till the module has been resolved.getArtifact
in interface EarModule
artifact
EarModule.resolveArtifact(java.util.Set)
public String getUri()
EarModule
URI
for this module.public String getType()
public String getArtifactId()
artifactId
public String getClassifier()
public String getBundleDir()
public String getLibDir()
public boolean isClassPathItem()
isClassPathItem
in interface EarModule
public String getBundleFileName()
null
, the artifact's file name is returned.getBundleFileName
in interface EarModule
public String getAltDeploymentDescriptor()
getAltDeploymentDescriptor
in interface EarModule
public boolean isExcluded()
isExcluded
in interface EarModule
public Boolean shouldUnpack()
EarModule
shouldUnpack
in interface EarModule
unpack
protected void writeAltDeploymentDescriptor(org.codehaus.plexus.util.xml.XMLWriter writer, String version)
writer
- the writer to useversion
- the java EE version in useprotected void startModuleElement(org.codehaus.plexus.util.xml.XMLWriter writer, Boolean generateId)
MODULE_ELEMENT
on the specified writer, possibly including an id attribute.writer
- the XML writer.generateId
- whether an id should be generatedpublic boolean changeManifestClasspath()
changeManifestClasspath
in interface EarModule
true
Copyright © 2002–2022 The Apache Software Foundation. All rights reserved.