Package org.apache.maven.api.model
Class Profile
java.lang.Object
org.apache.maven.api.model.ModelBase
org.apache.maven.api.model.Profile
- All Implemented Interfaces:
Serializable,InputLocationTracker
@Experimental
@Generated
@ThreadSafe
@Immutable
public class Profile
extends ModelBase
implements Serializable, InputLocationTracker
Modifications to the build process which is activated based on environmental
parameters or command line arguments.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classBuilder class used to create Profile instances. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionThe conditional logic which will automatically trigger the inclusion of this profile.getBuild()Information required to build the project.getId()The identifier of this build profile.static Profile.BuilderCreates a newProfilebuilder instance.static Profile.BuildernewBuilder(boolean withDefaults) Creates a newProfilebuilder instance using default values or not.static Profile.BuildernewBuilder(Profile from) Creates a newProfilebuilder instance using the specified object as a basis.static Profile.BuildernewBuilder(Profile from, boolean forceCopy) Creates a newProfilebuilder instance using the specified object as a basis.static ProfileCreates a newProfileinstance.static ProfilenewInstance(boolean withDefaults) Creates a newProfileinstance using default values or not.voidtoString()with()Creates a new builder with this object as the basis.withActivation(Activation activation) Creates a newProfileinstance using the specified activation.Creates a newProfileinstance using the specified build.withDependencies(Collection<Dependency> dependencies) Creates a newProfileinstance using the specified dependencies.withDependencyManagement(DependencyManagement dependencyManagement) Creates a newProfileinstance using the specified dependencyManagement.withDistributionManagement(DistributionManagement distributionManagement) Creates a newProfileinstance using the specified distributionManagement.Creates a newProfileinstance using the specified id.withModules(Collection<String> modules) Creates a newProfileinstance using the specified modules.withPluginRepositories(Collection<Repository> pluginRepositories) Creates a newProfileinstance using the specified pluginRepositories.withProperties(Map<String, String> properties) Creates a newProfileinstance using the specified properties.withReporting(Reporting reporting) Creates a newProfileinstance using the specified reporting.withRepositories(Collection<Repository> repositories) Creates a newProfileinstance using the specified repositories.Methods inherited from class org.apache.maven.api.model.ModelBase
getDependencies, getDependencyManagement, getDistributionManagement, getLocation, getModules, getPluginRepositories, getProperties, getReporting, getRepositories, newBuilder, newBuilderMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.maven.api.model.InputLocationTracker
getLocation
-
Field Details
-
SOURCE_POM
- See Also:
-
SOURCE_SETTINGS
- See Also:
-
-
Method Details
-
getId
The identifier of this build profile. This is used for command line activation, and identifies profiles to be merged.- Returns:
- a
String
-
getActivation
The conditional logic which will automatically trigger the inclusion of this profile.- Returns:
- a
Activation
-
getBuild
Information required to build the project.- Returns:
- a
BuildBase
-
with
Creates a new builder with this object as the basis. -
withModules
Creates a newProfileinstance using the specified modules.- Overrides:
withModulesin classModelBase- Parameters:
modules- the newCollection<String>to use- Returns:
- a
Profilewith the specified modules
-
withDistributionManagement
Creates a newProfileinstance using the specified distributionManagement.- Overrides:
withDistributionManagementin classModelBase- Parameters:
distributionManagement- the newDistributionManagementto use- Returns:
- a
Profilewith the specified distributionManagement
-
withProperties
Creates a newProfileinstance using the specified properties.- Overrides:
withPropertiesin classModelBase- Parameters:
properties- the newMap<String, String>to use- Returns:
- a
Profilewith the specified properties
-
withDependencyManagement
Creates a newProfileinstance using the specified dependencyManagement.- Overrides:
withDependencyManagementin classModelBase- Parameters:
dependencyManagement- the newDependencyManagementto use- Returns:
- a
Profilewith the specified dependencyManagement
-
withDependencies
Creates a newProfileinstance using the specified dependencies.- Overrides:
withDependenciesin classModelBase- Parameters:
dependencies- the newCollection<Dependency>to use- Returns:
- a
Profilewith the specified dependencies
-
withRepositories
Creates a newProfileinstance using the specified repositories.- Overrides:
withRepositoriesin classModelBase- Parameters:
repositories- the newCollection<Repository>to use- Returns:
- a
Profilewith the specified repositories
-
withPluginRepositories
Creates a newProfileinstance using the specified pluginRepositories.- Overrides:
withPluginRepositoriesin classModelBase- Parameters:
pluginRepositories- the newCollection<Repository>to use- Returns:
- a
Profilewith the specified pluginRepositories
-
withReporting
Creates a newProfileinstance using the specified reporting.- Overrides:
withReportingin classModelBase- Parameters:
reporting- the newReportingto use- Returns:
- a
Profilewith the specified reporting
-
withId
Creates a newProfileinstance using the specified id.- Parameters:
id- the newStringto use- Returns:
- a
Profilewith the specified id
-
withActivation
Creates a newProfileinstance using the specified activation.- Parameters:
activation- the newActivationto use- Returns:
- a
Profilewith the specified activation
-
withBuild
Creates a newProfileinstance using the specified build.- Parameters:
build- the newBuildBaseto use- Returns:
- a
Profilewith the specified build
-
newInstance
Creates a newProfileinstance. Equivalent tonewInstance(true).- Returns:
- a new
Profile - See Also:
-
newInstance
Creates a newProfileinstance using default values or not. Equivalent tonewBuilder(withDefaults).build().- Parameters:
withDefaults- the boolean indicating whether default values should be used- Returns:
- a new
Profile
-
newBuilder
Creates a newProfilebuilder instance. Equivalent tonewBuilder(true).- Returns:
- a new
Builder - See Also:
-
newBuilder
Creates a newProfilebuilder instance using default values or not.- Parameters:
withDefaults- the boolean indicating whether default values should be used- Returns:
- a new
Builder
-
newBuilder
Creates a newProfilebuilder instance using the specified object as a basis. Equivalent tonewBuilder(from, false).- Parameters:
from- theProfileinstance to use as a basis- Returns:
- a new
Builder
-
newBuilder
Creates a newProfilebuilder instance using the specified object as a basis.- Parameters:
from- theProfileinstance to use as a basisforceCopy- the boolean indicating if a copy should be forced- Returns:
- a new
Builder
-
setSource
-
getSource
-
toString
-