Package org.apache.maven.api.model
Class PluginExecution
java.lang.Object
org.apache.maven.api.model.ConfigurationContainer
org.apache.maven.api.model.PluginExecution
- All Implemented Interfaces:
- Serializable,- InputLocationTracker
@Experimental
@Generated
@ThreadSafe
@Immutable
public class PluginExecution
extends ConfigurationContainer
implements Serializable, InputLocationTracker
The 
<execution> element contains informations required for the
 execution of a plugin.- See Also:
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionstatic classBuilder class used to create PluginExecution instances.
- 
Field SummaryFields
- 
Method SummaryModifier and TypeMethodDescriptiongetGoals()The goals to execute with the given configuration.getId()The identifier of this execution for labelling the goals during the build, and for matching executions to merge during inheritance and profile injection.getPhase()The build lifecycle phase to bind the goals in this execution to.intThe priority of this execution compared to other executions which are bound to the same phase.static PluginExecution.BuilderCreates a newPluginExecutionbuilder instance.static PluginExecution.BuildernewBuilder(boolean withDefaults) Creates a newPluginExecutionbuilder instance using default values or not.static PluginExecution.BuildernewBuilder(PluginExecution from) Creates a newPluginExecutionbuilder instance using the specified object as a basis.static PluginExecution.BuildernewBuilder(PluginExecution from, boolean forceCopy) Creates a newPluginExecutionbuilder instance using the specified object as a basis.static PluginExecutionCreates a newPluginExecutioninstance.static PluginExecutionnewInstance(boolean withDefaults) Creates a newPluginExecutioninstance using default values or not.toString()with()Creates a new builder with this object as the basis.withConfiguration(XmlNode configuration) Creates a newPluginExecutioninstance using the specified configuration.withGoals(Collection<String> goals) Creates a newPluginExecutioninstance using the specified goals.Creates a newPluginExecutioninstance using the specified id.withInherited(String inherited) Creates a newPluginExecutioninstance using the specified inherited.Creates a newPluginExecutioninstance using the specified phase.withPriority(int priority) Creates a newPluginExecutioninstance using the specified priority.Methods inherited from class org.apache.maven.api.model.ConfigurationContainergetConfiguration, getInherited, getLocation, isInherited, newBuilder, newBuilderMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.maven.api.model.InputLocationTrackergetLocation
- 
Field Details- 
DEFAULT_EXECUTION_ID- See Also:
 
 
- 
- 
Method Details- 
getIdThe identifier of this execution for labelling the goals during the build, and for matching executions to merge during inheritance and profile injection.- Returns:
- a String
 
- 
getPhaseThe build lifecycle phase to bind the goals in this execution to. If omitted, the goals will be bound to the default phase specified by the plugin.- Returns:
- a String
 
- 
getPrioritypublic int getPriority()The priority of this execution compared to other executions which are bound to the same phase. Executions derived from the default lifecycle have a negative priority by default so that they are executed before any custom plugin executions.
 Since: Maven 4.0.0- Returns:
- a int
 
- 
getGoalsThe goals to execute with the given configuration.- Returns:
- a List<String>
 
- 
withCreates a new builder with this object as the basis.- Overrides:
- within class- ConfigurationContainer
- Returns:
- a Builder
 
- 
withInheritedCreates a newPluginExecutioninstance using the specified inherited.- Overrides:
- withInheritedin class- ConfigurationContainer
- Parameters:
- inherited- the new- Stringto use
- Returns:
- a PluginExecutionwith the specified inherited
 
- 
withConfigurationCreates a newPluginExecutioninstance using the specified configuration.- Overrides:
- withConfigurationin class- ConfigurationContainer
- Parameters:
- configuration- the new- XmlNodeto use
- Returns:
- a PluginExecutionwith the specified configuration
 
- 
withIdCreates a newPluginExecutioninstance using the specified id.- Parameters:
- id- the new- Stringto use
- Returns:
- a PluginExecutionwith the specified id
 
- 
withPhaseCreates a newPluginExecutioninstance using the specified phase.- Parameters:
- phase- the new- Stringto use
- Returns:
- a PluginExecutionwith the specified phase
 
- 
withPriorityCreates a newPluginExecutioninstance using the specified priority.- Parameters:
- priority- the new- intto use
- Returns:
- a PluginExecutionwith the specified priority
 
- 
withGoalsCreates a newPluginExecutioninstance using the specified goals.- Parameters:
- goals- the new- Collection<String>to use
- Returns:
- a PluginExecutionwith the specified goals
 
- 
newInstanceCreates a newPluginExecutioninstance. Equivalent tonewInstance(true).- Returns:
- a new PluginExecution
- See Also:
 
- 
newInstanceCreates a newPluginExecutioninstance using default values or not. Equivalent tonewBuilder(withDefaults).build().- Parameters:
- withDefaults- the boolean indicating whether default values should be used
- Returns:
- a new PluginExecution
 
- 
newBuilderCreates a newPluginExecutionbuilder instance. Equivalent tonewBuilder(true).- Returns:
- a new Builder
- See Also:
 
- 
newBuilderCreates a newPluginExecutionbuilder instance using default values or not.- Parameters:
- withDefaults- the boolean indicating whether default values should be used
- Returns:
- a new Builder
 
- 
newBuilderCreates a newPluginExecutionbuilder instance using the specified object as a basis. Equivalent tonewBuilder(from, false).- Parameters:
- from- the- PluginExecutioninstance to use as a basis
- Returns:
- a new Builder
 
- 
newBuilderCreates a newPluginExecutionbuilder instance using the specified object as a basis.- Parameters:
- from- the- PluginExecutioninstance to use as a basis
- forceCopy- the boolean indicating if a copy should be forced
- Returns:
- a new Builder
 
- 
toString
 
-