Annotation Type Mojo
-
@Documented @Retention(CLASS) @Target(TYPE) @Inherited public @interface Mojo
This annotation will mark your class as a Mojo (ie. goal in a Maven plugin).- Since:
- 3.0
- Author:
- Olivier Lamy
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description booleanaggregatorif the Mojo uses the Maven project and its child modules.Stringconfiguratorown configurator class.LifecyclePhasedefaultPhasedefault phase to bind your mojo.StringexecutionStrategyDeprecated.unusedbooleaninheritByDefaultDeprecated.unusedInstantiationStrategyinstantiationStrategyyour Mojo instantiation strategy.ResolutionScoperequiresDependencyCollectionthe required dependency collection scope.ResolutionScoperequiresDependencyResolutionthe required dependency resolution scope.booleanrequiresDirectInvocationDeprecated.unusedbooleanrequiresOnlinedoes this Mojo need to be online to be executed?booleanrequiresProjectdoes your mojo requires a project to be executed?booleanrequiresReportsDeprecated.unusedbooleanthreadSafeis your mojo thread safe (since Maven 3.x)?
-
-
-
-
defaultPhase
LifecyclePhase defaultPhase
default phase to bind your mojo.- Returns:
- the default phase
- Default:
- org.apache.maven.plugins.annotations.LifecyclePhase.NONE
-
-
-
requiresDependencyResolution
ResolutionScope requiresDependencyResolution
the required dependency resolution scope.- Returns:
- the required dependency resolution scope
- Default:
- org.apache.maven.plugins.annotations.ResolutionScope.NONE
-
-
-
requiresDependencyCollection
ResolutionScope requiresDependencyCollection
the required dependency collection scope.- Returns:
- the required dependency collection scope
- Default:
- org.apache.maven.plugins.annotations.ResolutionScope.NONE
-
-
-
instantiationStrategy
InstantiationStrategy instantiationStrategy
your Mojo instantiation strategy. (Onlyper-lookupandsingletonare supported)- Returns:
- the instantiation strategy
- Default:
- org.apache.maven.plugins.annotations.InstantiationStrategy.PER_LOOKUP
-
-
-
executionStrategy
@Deprecated String executionStrategy
Deprecated.unusedexecution strategy:once-per-sessionoralways.- Returns:
once-per-sessionoralways
- Default:
- "once-per-session"
-
-
-
requiresProject
boolean requiresProject
does your mojo requires a project to be executed?- Returns:
- requires a project
- Default:
- true
-
-
-
requiresReports
@Deprecated boolean requiresReports
Deprecated.unuseddoes your mojo requires a reporting context to be executed?- Returns:
- requires a reporting context
- Default:
- false
-
-
-
aggregator
boolean aggregator
if the Mojo uses the Maven project and its child modules.- Returns:
- uses the Maven project and its child modules
- Default:
- false
-
-
-
requiresDirectInvocation
@Deprecated boolean requiresDirectInvocation
Deprecated.unusedcan this Mojo be invoked directly only?- Returns:
- invoked directly only
- Default:
- false
-
-
-
requiresOnline
boolean requiresOnline
does this Mojo need to be online to be executed?- Returns:
- need to be online
- Default:
- false
-
-
-
inheritByDefault
@Deprecated boolean inheritByDefault
Deprecated.unused- Default:
- true
-
-
-
configurator
String configurator
own configurator class.- Returns:
- own configurator class
- Default:
- ""
-
-
-
threadSafe
boolean threadSafe
is your mojo thread safe (since Maven 3.x)?- Returns:
- is thread safe
- Default:
- false
-
-