public class Overlay
extends java.lang.Object
An overlay is a skeleton WAR added to another WAR project in order to inject a functionality, resources or any other shared component.
Note that a particular WAR dependency can be added multiple times as an overlay with different includes/excludes filter; this allows building a fine grained overwriting policy.
The current project can also be described as an overlay and can not be specified twice. An overlay with no groupId and no artifactId represents the current project.
| Modifier and Type | Field and Description |
|---|---|
private org.apache.maven.artifact.Artifact |
artifact |
private java.lang.String |
artifactId |
private java.lang.String |
classifier |
static java.lang.String[] |
DEFAULT_EXCLUDES
The list of default excludes.
|
static java.lang.String[] |
DEFAULT_INCLUDES
The list of default includes.
|
private java.lang.String[] |
excludes |
private boolean |
filtered |
private java.lang.String |
groupId |
private java.lang.String |
id |
private java.lang.String[] |
includes |
private boolean |
skip |
private java.lang.String |
targetPath |
private java.lang.String |
type
default overlay type is war
|
| Constructor and Description |
|---|
Overlay()
Create instance.
|
Overlay(java.lang.String groupId,
java.lang.String artifactId) |
| Modifier and Type | Method and Description |
|---|---|
static Overlay |
createInstance() |
boolean |
equals(java.lang.Object o) |
org.apache.maven.artifact.Artifact |
getArtifact() |
java.lang.String |
getArtifactId() |
java.lang.String |
getClassifier() |
java.lang.String[] |
getExcludes() |
java.lang.String |
getGroupId() |
java.lang.String |
getId() |
java.lang.String[] |
getIncludes() |
java.lang.String |
getTargetPath() |
java.lang.String |
getType() |
int |
hashCode() |
boolean |
isCurrentProject()
Specify whether this overlay represents the current project or not.
|
boolean |
isFiltered() |
private java.lang.String[] |
parse(java.lang.String s) |
void |
setArtifact(org.apache.maven.artifact.Artifact artifact) |
void |
setArtifactId(java.lang.String artifactId) |
void |
setClassifier(java.lang.String classifier) |
void |
setExcludes(java.lang.String excludes) |
void |
setExcludes(java.lang.String[] excludes) |
void |
setFiltered(boolean filtered) |
void |
setGroupId(java.lang.String groupId) |
void |
setId(java.lang.String id) |
void |
setIncludes(java.lang.String includes) |
void |
setIncludes(java.lang.String[] includes) |
void |
setSkip(boolean skip) |
void |
setTargetPath(java.lang.String targetPath) |
void |
setType(java.lang.String type) |
boolean |
shouldSkip() |
java.lang.String |
toString() |
public static final java.lang.String[] DEFAULT_INCLUDES
public static final java.lang.String[] DEFAULT_EXCLUDES
private java.lang.String id
private java.lang.String groupId
private java.lang.String artifactId
private java.lang.String classifier
private java.lang.String[] includes
private java.lang.String[] excludes
private boolean filtered
private boolean skip
private org.apache.maven.artifact.Artifact artifact
private java.lang.String targetPath
private java.lang.String type
public Overlay()
public Overlay(java.lang.String groupId,
java.lang.String artifactId)
groupId - groupIdartifactId - artifactIdpublic boolean isCurrentProject()
public java.lang.String getId()
public void setId(java.lang.String id)
id - The id.public java.lang.String getGroupId()
groupIdpublic void setGroupId(java.lang.String groupId)
groupId - groupIdpublic java.lang.String getArtifactId()
artifactIdpublic void setArtifactId(java.lang.String artifactId)
artifactId - artifactIdpublic java.lang.String getClassifier()
classifierpublic void setClassifier(java.lang.String classifier)
classifier - classifierpublic java.lang.String[] getIncludes()
includespublic void setIncludes(java.lang.String includes)
includes - includespublic void setIncludes(java.lang.String[] includes)
includes - includespublic java.lang.String[] getExcludes()
excludespublic void setExcludes(java.lang.String excludes)
excludes - excludespublic void setExcludes(java.lang.String[] excludes)
excludes - excludespublic boolean isFiltered()
filteredpublic void setFiltered(boolean filtered)
filtered - filteredpublic boolean shouldSkip()
skippublic void setSkip(boolean skip)
skip - skippublic org.apache.maven.artifact.Artifact getArtifact()
artifactpublic void setArtifact(org.apache.maven.artifact.Artifact artifact)
artifact - artifactpublic java.lang.String getTargetPath()
targetPathpublic void setTargetPath(java.lang.String targetPath)
targetPath - targetPathpublic java.lang.String getType()
typepublic void setType(java.lang.String type)
type - typepublic java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectprivate java.lang.String[] parse(java.lang.String s)