renamed DependencyScope to ResolutionScope to better match the intent

git-svn-id: https://svn.apache.org/repos/asf/maven/plugin-tools/trunk@1338393 13f79535-47bb-0310-9956-ffa450edef68
master
Herve Boutemy 2012-05-14 20:46:10 +00:00
parent 30fe737999
commit d56e6cba11
10 changed files with 25 additions and 25 deletions

View File

@ -40,9 +40,9 @@ public @interface Mojo
LifecyclePhase defaultPhase() default LifecyclePhase.NONE;
DependencyScope requiresDependencyResolution() default DependencyScope.RUNTIME;
ResolutionScope requiresDependencyResolution() default ResolutionScope.RUNTIME;
DependencyScope requiresDependencyCollection() default DependencyScope.RUNTIME;
ResolutionScope requiresDependencyCollection() default ResolutionScope.RUNTIME;
InstanciationStrategy instantiationStrategy() default InstanciationStrategy.PER_LOOKUP;

View File

@ -28,7 +28,7 @@ import org.apache.maven.artifact.Artifact;
* @author Hervé Boutemy
* @since 3.0
*/
public enum DependencyScope
public enum ResolutionScope
{
/**
* <code>compile</code> resolution scope
@ -59,7 +59,7 @@ public enum DependencyScope
private final String id;
DependencyScope( String id )
ResolutionScope( String id )
{
this.id = id;
}

View File

@ -21,7 +21,7 @@ package org.apache.maven.plugin.coreit;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Component;
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.Execute;
import org.apache.maven.plugins.annotations.LifecyclePhase;
import org.apache.maven.plugins.annotations.Mojo;
@ -34,7 +34,7 @@ import org.apache.maven.tools.plugin.annotations.FooMojo;
* @since 1.2
* @deprecated Don't use!
*/
@Mojo( name = "first", requiresDependencyResolution = DependencyScope.TEST, defaultPhase = LifecyclePhase.INTEGRATION_TEST )
@Mojo( name = "first", requiresDependencyResolution = ResolutionScope.TEST, defaultPhase = LifecyclePhase.INTEGRATION_TEST )
public class FirstMojo
extends FooMojo
{

View File

@ -21,7 +21,7 @@ package org.apache.maven.plugin.coreit;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Component;
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.Execute;
import org.apache.maven.plugins.annotations.LifecyclePhase;
import org.apache.maven.plugins.annotations.Mojo;
@ -34,7 +34,7 @@ import org.apache.maven.plugins.AbstractFirstMojo;
* @since 1.2
* @deprecated Don't use!
*/
@Mojo( name = "first", requiresDependencyResolution = DependencyScope.TEST, defaultPhase = LifecyclePhase.INTEGRATION_TEST )
@Mojo( name = "first", requiresDependencyResolution = ResolutionScope.TEST, defaultPhase = LifecyclePhase.INTEGRATION_TEST )
@Execute( phase = LifecyclePhase.GENERATE_SOURCES, lifecycle = "cobertura" )
public class FirstMojo
extends AbstractFirstMojo

View File

@ -20,14 +20,14 @@ package org.apache.maven.plugin.coreit;
*/
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.Mojo;
/**
* Does nothing special.
*
*/
@Mojo( name = "second", requiresDependencyCollection = DependencyScope.COMPILE, threadSafe = true )
@Mojo( name = "second", requiresDependencyCollection = ResolutionScope.COMPILE, threadSafe = true )
public class SecondMojo
extends AbstractMojo
{

View File

@ -22,7 +22,7 @@ package org.apache.maven.plugin.coreit;
import org.apache.maven.artifact.Artifact;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Component;
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.Execute;
import org.apache.maven.plugins.annotations.LifecyclePhase;
import org.apache.maven.plugins.annotations.Mojo;
@ -36,7 +36,7 @@ import java.util.Set;
* @since 1.2
* @deprecated Don't use!
*/
@Mojo( name = "first", requiresDependencyResolution = DependencyScope.COMPILE,
@Mojo( name = "first", requiresDependencyResolution = ResolutionScope.COMPILE,
defaultPhase = LifecyclePhase.INTEGRATION_TEST )
@Execute( phase = LifecyclePhase.GENERATE_SOURCES, lifecycle = "cobertura" )
public class FirstMojo

View File

@ -20,14 +20,14 @@ package org.apache.maven.plugin.coreit;
*/
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.Mojo;
/**
* Does nothing special.
*
*/
@Mojo( name = "second", requiresDependencyCollection = DependencyScope.COMPILE, threadSafe = true )
@Mojo( name = "second", requiresDependencyCollection = ResolutionScope.COMPILE, threadSafe = true )
public class SecondMojo
extends AbstractMojo
{

View File

@ -22,7 +22,7 @@ package org.apache.maven.plugin.coreit;
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Component;
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.Execute;
import org.apache.maven.plugins.annotations.LifecyclePhase;
import org.apache.maven.plugins.annotations.Mojo;
@ -36,7 +36,7 @@ import java.io.File;
* @since 1.2
* @deprecated Don't use!
*/
@Mojo( name = "first", requiresDependencyResolution = DependencyScope.TEST, defaultPhase = LifecyclePhase.INTEGRATION_TEST )
@Mojo( name = "first", requiresDependencyResolution = ResolutionScope.TEST, defaultPhase = LifecyclePhase.INTEGRATION_TEST )
@Execute( phase = LifecyclePhase.GENERATE_SOURCES, lifecycle = "cobertura" )
public class FirstMojo
extends AbstractMojo

View File

@ -20,14 +20,14 @@ package org.apache.maven.plugin.coreit;
*/
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.Mojo;
/**
* Does nothing special.
*
*/
@Mojo( name = "second", requiresDependencyCollection = DependencyScope.COMPILE, threadSafe = true )
@Mojo( name = "second", requiresDependencyCollection = ResolutionScope.COMPILE, threadSafe = true )
public class SecondMojo
extends AbstractMojo
{

View File

@ -19,7 +19,7 @@ package org.apache.maven.tools.plugin.annotations.datamodel;
* under the License.
*/
import org.apache.maven.plugins.annotations.DependencyScope;
import org.apache.maven.plugins.annotations.ResolutionScope;
import org.apache.maven.plugins.annotations.InstanciationStrategy;
import org.apache.maven.plugins.annotations.LifecyclePhase;
import org.apache.maven.plugins.annotations.Mojo;
@ -38,9 +38,9 @@ public class MojoAnnotationContent
private LifecyclePhase defaultPhase = LifecyclePhase.NONE;
private DependencyScope requiresDependencyResolution = DependencyScope.RUNTIME;
private ResolutionScope requiresDependencyResolution = ResolutionScope.RUNTIME;
private DependencyScope requiresDependencyCollection = DependencyScope.RUNTIME;
private ResolutionScope requiresDependencyCollection = ResolutionScope.RUNTIME;
private InstanciationStrategy instantiationStrategy = InstanciationStrategy.PER_LOOKUP;
@ -77,24 +77,24 @@ public class MojoAnnotationContent
this.defaultPhase = LifecyclePhase.valueOf( phase );
}
public DependencyScope requiresDependencyResolution()
public ResolutionScope requiresDependencyResolution()
{
return requiresDependencyResolution;
}
public void requiresDependencyResolution( String requiresDependencyResolution )
{
this.requiresDependencyResolution = DependencyScope.valueOf( requiresDependencyResolution );
this.requiresDependencyResolution = ResolutionScope.valueOf( requiresDependencyResolution );
}
public DependencyScope requiresDependencyCollection()
public ResolutionScope requiresDependencyCollection()
{
return requiresDependencyCollection;
}
public void requiresDependencyCollection( String requiresDependencyCollection )
{
this.requiresDependencyCollection = DependencyScope.valueOf( requiresDependencyCollection );
this.requiresDependencyCollection = ResolutionScope.valueOf( requiresDependencyCollection );
}
public InstanciationStrategy instantiationStrategy()