diff --git a/maven-compat/src/main/java/org/apache/maven/repository/MetadataResolutionRequest.java b/maven-compat/src/main/java/org/apache/maven/repository/MetadataResolutionRequest.java index c98dd053e1..7593351755 100644 --- a/maven-compat/src/main/java/org/apache/maven/repository/MetadataResolutionRequest.java +++ b/maven-compat/src/main/java/org/apache/maven/repository/MetadataResolutionRequest.java @@ -108,11 +108,24 @@ public class MetadataResolutionRequest return this; } + /** + * @deprecated instead use {@link #getRemoteRepositories()} + */ + @Deprecated public List getRemoteRepostories() { return remoteRepositories; } + public List getRemoteRepositories() + { + return getRemoteRepostories(); + } + + /** + * @deprecated instead use {@link #setRemoteRepositories()} + */ + @Deprecated public MetadataResolutionRequest setRemoteRepostories( List remoteRepostories ) { this.remoteRepositories = remoteRepostories; @@ -120,6 +133,11 @@ public class MetadataResolutionRequest return this; } + public MetadataResolutionRequest setRemoteRepositories( List remoteRepositories ) + { + return setRemoteRepostories( remoteRepositories ); + } + public Map getManagedVersionMap() { return managedVersionMap; diff --git a/maven-compat/src/main/java/org/apache/maven/repository/legacy/LegacyRepositorySystem.java b/maven-compat/src/main/java/org/apache/maven/repository/legacy/LegacyRepositorySystem.java index bd5988a5bb..8d4d40798d 100644 --- a/maven-compat/src/main/java/org/apache/maven/repository/legacy/LegacyRepositorySystem.java +++ b/maven-compat/src/main/java/org/apache/maven/repository/legacy/LegacyRepositorySystem.java @@ -329,7 +329,7 @@ public class LegacyRepositorySystem DelegatingLocalArtifactRepository delegatingLocalRepository = (DelegatingLocalArtifactRepository) request.getLocalRepository(); - LocalArtifactRepository orig = delegatingLocalRepository.getIdeWorspace(); + LocalArtifactRepository orig = delegatingLocalRepository.getIdeWorkspace(); delegatingLocalRepository.setIdeWorkspace( ideWorkspace ); diff --git a/maven-core/src/main/java/org/apache/maven/repository/DelegatingLocalArtifactRepository.java b/maven-core/src/main/java/org/apache/maven/repository/DelegatingLocalArtifactRepository.java index 90c1fa9a5c..eb8f5eae54 100644 --- a/maven-core/src/main/java/org/apache/maven/repository/DelegatingLocalArtifactRepository.java +++ b/maven-core/src/main/java/org/apache/maven/repository/DelegatingLocalArtifactRepository.java @@ -61,11 +61,20 @@ public class DelegatingLocalArtifactRepository this.ideWorkspace = localRepository; } + /** + * @deprecated instead use {@link #getIdeWorkspace()} + */ + @Deprecated public LocalArtifactRepository getIdeWorspace() { return ideWorkspace; } + public LocalArtifactRepository getIdeWorkspace() + { + return getIdeWorspace(); + } + @Override public Artifact find( Artifact artifact ) { diff --git a/maven-core/src/test/java/org/apache/maven/lifecycle/internal/stub/LifecycleExecutionPlanCalculatorStub.java b/maven-core/src/test/java/org/apache/maven/lifecycle/internal/stub/LifecycleExecutionPlanCalculatorStub.java index ad08549379..43aa47c8f4 100644 --- a/maven-core/src/test/java/org/apache/maven/lifecycle/internal/stub/LifecycleExecutionPlanCalculatorStub.java +++ b/maven-core/src/test/java/org/apache/maven/lifecycle/internal/stub/LifecycleExecutionPlanCalculatorStub.java @@ -87,7 +87,10 @@ public class LifecycleExecutionPlanCalculatorStub public final static MojoDescriptor SITE_DEPLOY = createMojoDescriptor( "site-deploy" ); - + /** + * @deprecated instead use {@link #getNumberOfExecutions()} + */ + @Deprecated public int getNumberOfExceutions( ProjectBuildList projectBuildList ) throws InvalidPluginDescriptorException, PluginVersionResolutionException, PluginDescriptorParsingException, NoPluginFoundForPrefixException, MojoNotFoundException, PluginNotFoundException, PluginResolutionException, @@ -103,6 +106,14 @@ public class LifecycleExecutionPlanCalculatorStub return result; } + public int getNumberOfExecutions( ProjectBuildList projectBuildList ) + throws InvalidPluginDescriptorException, PluginVersionResolutionException, PluginDescriptorParsingException, + NoPluginFoundForPrefixException, MojoNotFoundException, PluginNotFoundException, PluginResolutionException, + LifecyclePhaseNotFoundException, LifecycleNotFoundException + { + return getNumberOfExceutions( projectBuildList ); + } + public void calculateForkedExecutions( MojoExecution mojoExecution, MavenSession session ) throws MojoNotFoundException, PluginNotFoundException, PluginResolutionException, PluginDescriptorParsingException, NoPluginFoundForPrefixException, InvalidPluginDescriptorException, diff --git a/maven-model-builder/src/test/java/org/apache/maven/model/interpolation/AbstractModelInterpolatorTest.java b/maven-model-builder/src/test/java/org/apache/maven/model/interpolation/AbstractModelInterpolatorTest.java index b56bc15553..d8b54b8618 100644 --- a/maven-model-builder/src/test/java/org/apache/maven/model/interpolation/AbstractModelInterpolatorTest.java +++ b/maven-model-builder/src/test/java/org/apache/maven/model/interpolation/AbstractModelInterpolatorTest.java @@ -67,6 +67,10 @@ public abstract class AbstractModelInterpolatorTest assertEquals( "Expected no fatals", 0, collector.getFatals().size() ); } + /** + * @deprecated instead use {@link #assertCollectorState()} + */ + @Deprecated protected void assertColllectorState( int numFatals, int numErrors, int numWarnings, SimpleProblemCollector collector ) { @@ -75,6 +79,12 @@ public abstract class AbstractModelInterpolatorTest assertEquals( "Fatals", numFatals, collector.getFatals().size() ); } + protected void assertCollectorState( int numFatals, int numErrors, int numWarnings, + SimpleProblemCollector collector ) + { + assertColllectorState(numFatals, numErrors, numWarnings, collector); + } + private ModelBuildingRequest createModelBuildingRequest( Properties p ) { ModelBuildingRequest config = new DefaultModelBuildingRequest(); @@ -178,7 +188,7 @@ public abstract class AbstractModelInterpolatorTest final SimpleProblemCollector collector = new SimpleProblemCollector(); interpolator.interpolateModel( model, null, createModelBuildingRequest( context ), collector ); - assertColllectorState( 0, 1, 0, collector ); + assertCollectorState( 0, 1, 0, collector ); } catch ( Exception e ) { @@ -247,7 +257,7 @@ public abstract class AbstractModelInterpolatorTest final SimpleProblemCollector collector = new SimpleProblemCollector(); Model out = interpolator.interpolateModel( model, new File( "." ), createModelBuildingRequest( context ), collector ); - assertColllectorState(0, 0, 1, collector ); + assertCollectorState(0, 0, 1, collector ); assertEquals( "3.8.1", ( out.getDependencies().get( 0 ) ).getVersion() ); } @@ -305,7 +315,7 @@ public abstract class AbstractModelInterpolatorTest final SimpleProblemCollector collector = new SimpleProblemCollector(); Model out = interpolator.interpolateModel( model, new File( "." ), createModelBuildingRequest( context ), collector ); - assertColllectorState( 0, 0, 2, collector ); + assertCollectorState( 0, 0, 2, collector ); assertEquals( "foo-3.8.1", ( out.getDependencies().get( 0 ) ).getVersion() ); } @@ -450,7 +460,7 @@ public abstract class AbstractModelInterpolatorTest final SimpleProblemCollector collector = new SimpleProblemCollector(); Model out = interpolator.interpolateModel( model, null, createModelBuildingRequest( context ), collector ); - assertColllectorState( 0, 0, 2, collector ); + assertCollectorState( 0, 0, 2, collector ); List outResources = out.getBuild().getResources();