@Mojo(name="build-classpath",
requiresDependencyResolution=TEST,
defaultPhase=GENERATE_SOURCES,
threadSafe=true)
public class BuildClasspathMojo
extends AbstractDependencyFilterMojo
implements Comparator<org.apache.maven.artifact.Artifact>
classifier, excludeArtifactIds, excludeClassifiers, excludeGroupIds, excludeScope, excludeTransitive, excludeTypes, includeArtifactIds, includeClassifiers, includeGroupIds, includeScope, includeTypes, markersDirectory, overWriteIfNewer, overWriteReleases, overWriteSnapshots, prependGroupId, typeoutputAbsoluteArtifactFilename, reactorProjects, session| Constructor and Description |
|---|
BuildClasspathMojo() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
appendArtifactPath(org.apache.maven.artifact.Artifact art,
StringBuilder sb)
Appends the artifact path into the specified StringBuilder.
|
protected void |
attachFile(String cpString) |
int |
compare(org.apache.maven.artifact.Artifact art1,
org.apache.maven.artifact.Artifact art2)
Compares artifacts lexicographically, using pattern [group_id][artifact_id][version].
|
protected void |
doExecute()
Main entry into mojo.
|
protected org.apache.maven.shared.artifact.filter.collection.ArtifactsFilter |
getMarkedArtifactFilter()
Return an
ArtifactsFilter indicating which artifacts must be filtered out. |
boolean |
isStripVersion() |
protected String |
readClasspathFile()
Reads the file specified by the mojo param 'outputFile' into a string.
|
void |
setFileSeparator(String theFileSeparator) |
void |
setLocalRepoProperty(String localRepoProperty) |
void |
setOutputFile(File outputFile) |
void |
setOutputProperty(String theOutputProperty) |
void |
setPathSeparator(String thePathSeparator) |
void |
setPrefix(String thePrefix) |
void |
setRegenerateFile(boolean theRegenerateFile) |
void |
setStripVersion(boolean theStripVersion) |
filterMarkedDependencies, getArtifactResolver, getClassifierTranslatedDependencies, getDependencyResolver, getDependencySets, getDependencySets, getMarkersDirectory, getRepositoryManager, getResolvedDependencies, isPrependGroupId, resolve, setMarkersDirectory, setPrependGroupIdcopyFile, execute, getProject, isSilent, isSkip, newResolveArtifactProjectBuildingRequest, newResolvePluginProjectBuildingRequest, setSilent, setSkipgetLog, getPluginContext, setLog, setPluginContextclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcomparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongprotected void doExecute()
throws org.apache.maven.plugin.MojoExecutionException
doExecute in class AbstractDependencyMojoorg.apache.maven.plugin.MojoExecutionException - with a message if an error occurs.AbstractDependencyFilterMojo.getResolvedDependencies(boolean)protected void attachFile(String cpString) throws org.apache.maven.plugin.MojoExecutionException
cpString - The classpath.org.apache.maven.plugin.MojoExecutionException - in case of an error.protected void appendArtifactPath(org.apache.maven.artifact.Artifact art,
StringBuilder sb)
art - Artifactsb - StringBuilderprotected String readClasspathFile() throws IOException
IOException - in case of an errorpublic int compare(org.apache.maven.artifact.Artifact art1,
org.apache.maven.artifact.Artifact art2)
compare in interface Comparator<org.apache.maven.artifact.Artifact>art1 - first objectart2 - second object0 if the argument string is equal to this string; a value less than 0
if this string is lexicographically less than the string argument; and a value greater than
0 if this string is lexicographically greater than the string argument.protected org.apache.maven.shared.artifact.filter.collection.ArtifactsFilter getMarkedArtifactFilter()
AbstractDependencyFilterMojoArtifactsFilter indicating which artifacts must be filtered out.getMarkedArtifactFilter in class AbstractDependencyFilterMojoArtifactsFilter indicating which artifacts must be filtered out.public void setOutputFile(File outputFile)
outputFile - the outputFile to setpublic void setOutputProperty(String theOutputProperty)
theOutputProperty - the outputProperty to setpublic void setFileSeparator(String theFileSeparator)
theFileSeparator - the fileSeparator to setpublic void setPathSeparator(String thePathSeparator)
thePathSeparator - the pathSeparator to setpublic void setPrefix(String thePrefix)
thePrefix - the prefix to setpublic void setRegenerateFile(boolean theRegenerateFile)
theRegenerateFile - the regenerateFile to setpublic boolean isStripVersion()
public void setStripVersion(boolean theStripVersion)
theStripVersion - the stripVersion to setpublic void setLocalRepoProperty(String localRepoProperty)
localRepoProperty - localRepoPropertyCopyright © 2002–2023 The Apache Software Foundation. All rights reserved.