public class ArtifactRepository extends Object
EarModule
.Constructor and Description |
---|
ArtifactRepository(Set<org.apache.maven.artifact.Artifact> artifacts,
String mainArtifactId,
ArtifactTypeMappingService artifactTypeMappingService)
Creates a new repository with the specified artifacts.
|
Modifier and Type | Method and Description |
---|---|
Set<org.apache.maven.artifact.Artifact> |
getArtifacts(String groupId,
String artifactId,
String type)
Returns the artifacts with the specified parameters.
|
org.apache.maven.artifact.Artifact |
getUniqueArtifact(String groupId,
String artifactId,
String type)
Returns the artifact with the specified parameters.
|
org.apache.maven.artifact.Artifact |
getUniqueArtifact(String groupId,
String artifactId,
String type,
String classifier)
Returns the artifact with the specified parameters.
|
public ArtifactRepository(Set<org.apache.maven.artifact.Artifact> artifacts, String mainArtifactId, ArtifactTypeMappingService artifactTypeMappingService)
artifacts
- the artifactsmainArtifactId
- the id to use for the main artifact (no classifier)artifactTypeMappingService
- ArtifactTypeMappingService
public org.apache.maven.artifact.Artifact getUniqueArtifact(String groupId, String artifactId, String type, String classifier)
If the artifact is classified and is the only one with the specified groupI, artifactId and type, it will be returned.
If the artifact is classified and is not the only one with the specified groupI, artifactId and type, it returns null.
If the artifact is not found, it returns null.groupId
- the group idartifactId
- the artifact idtype
- the typeclassifier
- the classifierpublic org.apache.maven.artifact.Artifact getUniqueArtifact(String groupId, String artifactId, String type)
If the artifact is classified and is the only one with the specified groupI, artifactId and type, it will be returned.
If the artifact is classified and is not the only one with the specified groupI, artifactId and type, it returns null.
If the artifact is not found, it returns null.groupId
- the group idartifactId
- the artifact idtype
- the typepublic Set<org.apache.maven.artifact.Artifact> getArtifacts(String groupId, String artifactId, String type)
groupId
- the group idartifactId
- the artifact idtype
- the typeCopyright © 2002–2022 The Apache Software Foundation. All rights reserved.