Package org.apache.maven.project
Class DefaultProjectBuilder
java.lang.Object
org.apache.maven.project.DefaultProjectBuilder
- All Implemented Interfaces:
- ProjectBuilder
DefaultProjectBuilder
- 
Nested Class SummaryNested Classes
- 
Field SummaryFields
- 
Constructor SummaryConstructorsConstructorDescriptionDefaultProjectBuilder(ModelBuilder modelBuilder, ModelProcessor modelProcessor, ProjectBuildingHelper projectBuildingHelper, MavenRepositorySystem repositorySystem, org.eclipse.aether.RepositorySystem repoSystem, org.eclipse.aether.impl.RemoteRepositoryManager repositoryManager, ProjectDependenciesResolver dependencyResolver, RootLocator rootLocator) 
- 
Method SummaryModifier and TypeMethodDescriptionbuild(File pomFile, ProjectBuildingRequest request) Builds a project descriptor from the specified POM file.build(List<File> pomFiles, boolean recursive, ProjectBuildingRequest request) Builds the projects for the specified POM files and optionally their children.build(ModelSource modelSource, ProjectBuildingRequest request) Builds a project descriptor for the specified model source.build(Artifact artifact, boolean allowStubModel, ProjectBuildingRequest request) Builds a project descriptor for the specified artifact.build(Artifact artifact, ProjectBuildingRequest request) Builds a project descriptor for the specified artifact.build(ModelSource modelSource, ProjectBuildingRequest request) Deprecated.
- 
Field Details- 
DEFAULT_BUILDER_PARALLELISMpublic static final int DEFAULT_BUILDER_PARALLELISM
 
- 
- 
Constructor Details- 
DefaultProjectBuilder@Inject public DefaultProjectBuilder(ModelBuilder modelBuilder, ModelProcessor modelProcessor, ProjectBuildingHelper projectBuildingHelper, MavenRepositorySystem repositorySystem, org.eclipse.aether.RepositorySystem repoSystem, org.eclipse.aether.impl.RemoteRepositoryManager repositoryManager, ProjectDependenciesResolver dependencyResolver, RootLocator rootLocator) 
 
- 
- 
Method Details- 
buildpublic ProjectBuildingResult build(File pomFile, ProjectBuildingRequest request) throws ProjectBuildingException Description copied from interface:ProjectBuilderBuilds a project descriptor from the specified POM file.- Specified by:
- buildin interface- ProjectBuilder
- Parameters:
- pomFile- The POM file to build the project from, must not be- null.
- request- The project building request that holds further parameters, must not be- null.
- Returns:
- The result of the project building, never null.
- Throws:
- ProjectBuildingException- If the project descriptor could not be successfully built.
 
- 
build@Deprecated public ProjectBuildingResult build(ModelSource modelSource, ProjectBuildingRequest request) throws ProjectBuildingException Deprecated.Description copied from interface:ProjectBuilderBuilds a project descriptor for the specified model source.- Specified by:
- buildin interface- ProjectBuilder
- Parameters:
- modelSource- The source of the model to build the project descriptor from, must not be- null.
- request- The project building request that holds further parameters, must not be- null.
- Returns:
- The result of the project building, never null.
- Throws:
- ProjectBuildingException- If the project descriptor could not be successfully built.
- See Also:
 
- 
buildpublic ProjectBuildingResult build(ModelSource modelSource, ProjectBuildingRequest request) throws ProjectBuildingException Description copied from interface:ProjectBuilderBuilds a project descriptor for the specified model source.- Specified by:
- buildin interface- ProjectBuilder
- Parameters:
- modelSource- The source of the model to build the project descriptor from, must not be- null.
- request- The project building request that holds further parameters, must not be- null.
- Returns:
- The result of the project building, never null.
- Throws:
- ProjectBuildingException- If the project descriptor could not be successfully built.
- See Also:
 
- 
buildpublic ProjectBuildingResult build(Artifact artifact, ProjectBuildingRequest request) throws ProjectBuildingException Description copied from interface:ProjectBuilderBuilds a project descriptor for the specified artifact.- Specified by:
- buildin interface- ProjectBuilder
- Parameters:
- artifact- The POM artifact to build the project from, must not be- null.
- request- The project building request that holds further parameters, must not be- null.
- Returns:
- The result of the project building, never null.
- Throws:
- ProjectBuildingException- If the project descriptor could not be successfully built.
 
- 
buildpublic ProjectBuildingResult build(Artifact artifact, boolean allowStubModel, ProjectBuildingRequest request) throws ProjectBuildingException Description copied from interface:ProjectBuilderBuilds a project descriptor for the specified artifact.- Specified by:
- buildin interface- ProjectBuilder
- Parameters:
- artifact- The POM artifact to build the project from, must not be- null.
- allowStubModel- A flag controlling the case of a missing POM artifact. If- trueand the specified POM artifact does not exist, a simple stub model will be returned. If- false, an exception will be thrown.
- request- The project building request that holds further parameters, must not be- null.
- Returns:
- The result of the project building, never null.
- Throws:
- ProjectBuildingException- If the project descriptor could not be successfully built.
 
- 
buildpublic List<ProjectBuildingResult> build(List<File> pomFiles, boolean recursive, ProjectBuildingRequest request) throws ProjectBuildingException Description copied from interface:ProjectBuilderBuilds the projects for the specified POM files and optionally their children.- Specified by:
- buildin interface- ProjectBuilder
- Parameters:
- pomFiles- The POM files to build, must not be- null.
- recursive-- trueto recursively build submodules referenced by the POM files,- falseto build only the specified POM files.
- request- The project builder configuration that provides further parameters, must not be- null.
- Returns:
- The results of the project builder where each result corresponds to one project that was built, never
         null.
- Throws:
- ProjectBuildingException- If an error was encountered during building of any project.- ProjectBuildingException.getResults()provides access to the details of the problems.
 
 
-