Package org.apache.maven.execution
Class ProfileActivation
java.lang.Object
org.apache.maven.execution.ProfileActivation
Container for storing the request from the user to activate or de-activate certain profiles and optionally fail the
build if those profiles do not exist.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidMark a profile as optional and activated.voidMark a profile as required and activated.voidaddProfileActivation(String id, boolean active, boolean optional) Adds a profile activation to the request.voidMark a profile as optional and deactivated.voidMark a profile as required and deactivated.Deprecated.Deprecated.UsegetRequiredInactiveProfileIds()andgetOptionalInactiveProfileIds()instead.voidoverwriteActiveProfiles(List<String> activeProfileIds) Deprecated.UseactivateOptionalProfile(String)oractivateRequiredProfile(String)instead.voidoverwriteInactiveProfiles(List<String> inactiveProfileIds) Deprecated.UsedeactivateOptionalProfile(String)ordeactivateRequiredProfile(String)instead.
-
Constructor Details
-
ProfileActivation
public ProfileActivation()
-
-
Method Details
-
getActiveProfiles
Deprecated.UsegetRequiredActiveProfileIds()andgetOptionalActiveProfileIds()instead.Mimics the pre-Maven 4 "active profiles" list. -
getInactiveProfiles
Deprecated.UsegetRequiredInactiveProfileIds()andgetOptionalInactiveProfileIds()instead.Mimics the pre-Maven 4 "inactive profiles" list. -
overwriteActiveProfiles
Deprecated.UseactivateOptionalProfile(String)oractivateRequiredProfile(String)instead.Overwrites the active profiles based on a pre-Maven 4 "active profiles" list.- Parameters:
activeProfileIds- AListof profile IDs that must be activated.
-
overwriteInactiveProfiles
Deprecated.UsedeactivateOptionalProfile(String)ordeactivateRequiredProfile(String)instead.Overwrites the inactive profiles based on a pre-Maven 4 "inactive profiles" list.- Parameters:
inactiveProfileIds- AListof profile IDs that must be deactivated.
-
activateRequiredProfile
Mark a profile as required and activated.- Parameters:
id- The identifier of the profile.
-
activateOptionalProfile
Mark a profile as optional and activated.- Parameters:
id- The identifier of the profile.
-
deactivateRequiredProfile
Mark a profile as required and deactivated.- Parameters:
id- The identifier of the profile.
-
deactivateOptionalProfile
Mark a profile as optional and deactivated.- Parameters:
id- The identifier of the profile.
-
addProfileActivation
Adds a profile activation to the request.- Parameters:
id- The identifier of the profile.active- Should the profile be activated?optional- Can the build continue if the profile does not exist?
-
getRequiredActiveProfileIds
- Returns:
- Required active profile identifiers, never
null.
-
getOptionalActiveProfileIds
- Returns:
- Optional active profile identifiers, never
null.
-
getRequiredInactiveProfileIds
- Returns:
- Required inactive profile identifiers, never
null.
-
getOptionalInactiveProfileIds
- Returns:
- Optional inactive profile identifiers, never
null.
-
getRequiredActiveProfileIds()andgetOptionalActiveProfileIds()instead.