@Component(role=MavenProjectHelper.class) public class DefaultMavenProjectHelper extends org.codehaus.plexus.logging.AbstractLogEnabled implements MavenProjectHelper
ROLE
Constructor and Description |
---|
DefaultMavenProjectHelper() |
Modifier and Type | Method and Description |
---|---|
void |
addResource(MavenProject project,
String resourceDirectory,
List<String> includes,
List<String> excludes)
Add a resource directory to the project.
|
void |
addTestResource(MavenProject project,
String resourceDirectory,
List<String> includes,
List<String> excludes)
Add a test resource directory to the project.
|
void |
attachArtifact(MavenProject project,
Artifact artifact)
Add an attached artifact or replace the file for an existing artifact.
|
void |
attachArtifact(MavenProject project,
File artifactFile,
String artifactClassifier)
See
MavenProjectHelper.attachArtifact(MavenProject, String, String, java.io.File) , but with type set to null. |
void |
attachArtifact(MavenProject project,
String artifactType,
File artifactFile)
* See
MavenProjectHelper.attachArtifact(MavenProject, String, String, java.io.File) , but with classifier set to null. |
void |
attachArtifact(MavenProject project,
String artifactType,
String artifactClassifier,
File artifactFile)
Add or replace an artifact to the current project.
|
public void attachArtifact(MavenProject project, String artifactType, String artifactClassifier, File artifactFile)
MavenProjectHelper
attachArtifact
in interface MavenProjectHelper
project
- the project reference.artifactType
- the type (e.g. jar) or null.artifactClassifier
- the classifier or null.artifactFile
- the file for the artifact.public void attachArtifact(MavenProject project, String artifactType, File artifactFile)
MavenProjectHelper
MavenProjectHelper.attachArtifact(MavenProject, String, String, java.io.File)
, but with classifier set to null.attachArtifact
in interface MavenProjectHelper
project
- project reference.artifactType
- artifact type.artifactFile
- artifact file.public void attachArtifact(MavenProject project, File artifactFile, String artifactClassifier)
MavenProjectHelper
MavenProjectHelper.attachArtifact(MavenProject, String, String, java.io.File)
, but with type set to null.attachArtifact
in interface MavenProjectHelper
project
- project reference.artifactFile
- artifact file.artifactClassifier
- artifact classifier.public void attachArtifact(MavenProject project, Artifact artifact)
project
- project reference.artifact
- artifact to add or replace.MavenProject.addAttachedArtifact(org.apache.maven.artifact.Artifact)
public void addResource(MavenProject project, String resourceDirectory, List<String> includes, List<String> excludes)
MavenProjectHelper
addResource
in interface MavenProjectHelper
project
- project reference.resourceDirectory
- directory.includes
- include patterns.excludes
- exclude patterns.public void addTestResource(MavenProject project, String resourceDirectory, List<String> includes, List<String> excludes)
MavenProjectHelper
addTestResource
in interface MavenProjectHelper
project
- project reference.resourceDirectory
- directory.includes
- include patterns.excludes
- exclude patterns.Copyright © 2001–2023 The Apache Software Foundation. All rights reserved.