View Javadoc
1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one
3    * or more contributor license agreements.  See the NOTICE file
4    * distributed with this work for additional information
5    * regarding copyright ownership.  The ASF licenses this file
6    * to you under the Apache License, Version 2.0 (the
7    * "License"); you may not use this file except in compliance
8    * with the License.  You may obtain a copy of the License at
9    *
10   *   http://www.apache.org/licenses/LICENSE-2.0
11   *
12   * Unless required by applicable law or agreed to in writing,
13   * software distributed under the License is distributed on an
14   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15   * KIND, either express or implied.  See the License for the
16   * specific language governing permissions and limitations
17   * under the License.
18   */
19  package org.apache.maven.project;
20  
21  import java.io.File;
22  import java.util.List;
23  import org.apache.maven.artifact.Artifact;
24  import org.apache.maven.artifact.repository.ArtifactRepository;
25  import org.apache.maven.artifact.resolver.ArtifactNotFoundException;
26  import org.apache.maven.artifact.resolver.ArtifactResolutionException;
27  import org.apache.maven.profiles.ProfileManager;
28  import org.apache.maven.wagon.events.TransferListener;
29  
30  /**
31   * @deprecated use {@link ProjectBuilder} instead
32   */
33  @Deprecated
34  public interface MavenProjectBuilder {
35  
36      MavenProject build(File pom, ProjectBuilderConfiguration configuration) throws ProjectBuildingException;
37  
38      // TODO maven-site-plugin -- not used by the plugin directly, but used by Doxia Integration Tool & MPIR
39      // see DOXIASITETOOLS-167 & MPIR-349
40      MavenProject build(File pom, ArtifactRepository localRepository, ProfileManager profileManager)
41              throws ProjectBuildingException;
42  
43      // TODO remote-resources-plugin
44      MavenProject buildFromRepository(
45              Artifact artifact, List<ArtifactRepository> remoteRepositories, ArtifactRepository localRepository)
46              throws ProjectBuildingException;
47  
48      // TODO remote-resources-plugin
49      MavenProject buildFromRepository(
50              Artifact artifact,
51              List<ArtifactRepository> remoteRepositories,
52              ArtifactRepository localRepository,
53              boolean allowStubModel)
54              throws ProjectBuildingException;
55  
56      // TODO this is only to provide a project for plugins that don't need a project to execute but need some
57      // of the values from a MavenProject. Ideally this should be something internal and nothing outside Maven
58      // would ever need this so it should not be exposed in a public API
59      MavenProject buildStandaloneSuperProject(ProjectBuilderConfiguration configuration) throws ProjectBuildingException;
60  
61      MavenProject buildStandaloneSuperProject(ArtifactRepository localRepository) throws ProjectBuildingException;
62  
63      MavenProject buildStandaloneSuperProject(ArtifactRepository localRepository, ProfileManager profileManager)
64              throws ProjectBuildingException;
65  
66      MavenProject buildWithDependencies(
67              File pom,
68              ArtifactRepository localRepository,
69              ProfileManager globalProfileManager,
70              TransferListener transferListener)
71              throws ProjectBuildingException, ArtifactResolutionException, ArtifactNotFoundException;
72  
73      MavenProject buildWithDependencies(
74              File pom, ArtifactRepository localRepository, ProfileManager globalProfileManager)
75              throws ProjectBuildingException, ArtifactResolutionException, ArtifactNotFoundException;
76  }