o adding backward compat method in the project builder

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@597162 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jason van Zyl 2007-11-21 17:51:56 +00:00
parent deca7349ff
commit 40326eef36
4 changed files with 22 additions and 8 deletions

View File

@ -405,7 +405,7 @@ public class MavenEmbedder
try try
{ {
projectBuildingResult = mavenProjectBuilder.buildWithDependencies( projectBuildingResult = mavenProjectBuilder.buildProjectWithDependencies(
request.getPom(), request.getPom(),
request.getLocalRepository(), request.getLocalRepository(),
request.getProfileManager() ); request.getProfileManager() );

View File

@ -247,7 +247,17 @@ public class DefaultMavenProjectBuilder
return superProject; return superProject;
} }
public MavenProjectBuildingResult buildWithDependencies( File projectDescriptor, /** @since 2.0.x */
public MavenProject buildWithDependencies( File projectDescriptor,
ArtifactRepository localRepository,
ProfileManager profileManager )
throws ProjectBuildingException
{
return buildProjectWithDependencies( projectDescriptor, localRepository, profileManager ).getProject();
}
/** @since 2.1 */
public MavenProjectBuildingResult buildProjectWithDependencies( File projectDescriptor,
ArtifactRepository localRepository, ArtifactRepository localRepository,
ProfileManager profileManager ) ProfileManager profileManager )
throws ProjectBuildingException throws ProjectBuildingException

View File

@ -62,12 +62,17 @@ public interface MavenProjectBuilder
ProfileManager globalProfileManager ) ProfileManager globalProfileManager )
throws ProjectBuildingException; throws ProjectBuildingException;
MavenProject buildWithDependencies( File project,
MavenProjectBuildingResult buildWithDependencies( File project, ArtifactRepository localRepository,
ArtifactRepository localRepository, ProfileManager globalProfileManager )
ProfileManager globalProfileManager )
throws ProjectBuildingException; throws ProjectBuildingException;
MavenProjectBuildingResult buildProjectWithDependencies( File project,
ArtifactRepository localRepository,
ProfileManager globalProfileManager )
throws ProjectBuildingException;
MavenProject buildFromRepository( Artifact artifact, MavenProject buildFromRepository( Artifact artifact,
List remoteArtifactRepositories, List remoteArtifactRepositories,
ArtifactRepository localRepository ) ArtifactRepository localRepository )
@ -81,7 +86,6 @@ public interface MavenProjectBuilder
throws ProjectBuildingException; throws ProjectBuildingException;
/** /**
*
* @return * @return
* @throws ProjectBuildingException * @throws ProjectBuildingException
*/ */

View File

@ -106,7 +106,7 @@ public abstract class AbstractMavenProjectTestCase
protected MavenProject getProjectWithDependencies( File pom ) protected MavenProject getProjectWithDependencies( File pom )
throws Exception throws Exception
{ {
return projectBuilder.buildWithDependencies( pom, getLocalRepository(), null ).getProject(); return projectBuilder.buildWithDependencies( pom, getLocalRepository(), null );
} }
protected MavenProject getProject( File pom ) protected MavenProject getProject( File pom )