public class FlattenModelResolver extends Object implements org.apache.maven.model.resolution.ModelResolver
ModelResolver to emulate the maven POM resolution in order to build the
flattened POM.FlattenMojo| Constructor and Description |
|---|
FlattenModelResolver(org.apache.maven.artifact.repository.ArtifactRepository localRepository,
org.apache.maven.artifact.factory.ArtifactFactory artifactFactory)
The constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addRepository(org.apache.maven.model.Repository repository) |
void |
addRepository(org.apache.maven.model.Repository repository,
boolean replace) |
org.apache.maven.model.resolution.ModelResolver |
newCopy() |
void |
resetRepositories() |
org.apache.maven.model.building.ModelSource |
resolveModel(org.apache.maven.model.Parent parent)
Resolves the POM for the specified parent.
|
org.apache.maven.model.building.ModelSource |
resolveModel(String groupId,
String artifactId,
String version) |
public FlattenModelResolver(org.apache.maven.artifact.repository.ArtifactRepository localRepository,
org.apache.maven.artifact.factory.ArtifactFactory artifactFactory)
localRepository - is the local repository.artifactFactory - is the factory used to create project artifact instances.public org.apache.maven.model.building.ModelSource resolveModel(String groupId, String artifactId, String version)
resolveModel in interface org.apache.maven.model.resolution.ModelResolverpublic void addRepository(org.apache.maven.model.Repository repository)
addRepository in interface org.apache.maven.model.resolution.ModelResolverpublic org.apache.maven.model.resolution.ModelResolver newCopy()
newCopy in interface org.apache.maven.model.resolution.ModelResolverpublic org.apache.maven.model.building.ModelSource resolveModel(org.apache.maven.model.Parent parent)
parent - the parent coordinates to resolve, must not be nullnullpublic void resetRepositories()
public void addRepository(org.apache.maven.model.Repository repository,
boolean replace)
repository - The repository to add to the internal search chain, must not be null.replace - {true} when repository with same id should be replaced, otherwise false.Copyright © 2014–2015 MojoHaus. All rights reserved.