Package org.codehaus.mojo.flatten
Enum FlattenMode
- java.lang.Object
-
- java.lang.Enum<FlattenMode>
-
- org.codehaus.mojo.flatten.FlattenMode
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<FlattenMode>
public enum FlattenMode extends java.lang.Enum<FlattenMode>
This enum contains the predefined modes how to deal withadditional POM elements
whengenerating the flattened POM
.- Since:
- 1.0.0-beta-2
-
-
Enum Constant Summary
Enum Constants Enum Constant Description bom
clean
Removes alloptional POM elements
.defaults
The default mode that removes alloptional POM elements
exceptrepositories
.fatjar
Removes alloptional POM elements
and dependencies.minimum
Deprecated.confusing name, unstable contract.oss
For Open-Source-Software projects that want to keep alloptional POM elements
except forrepositories
andpluginRepositories
.ossrh
Keeps alloptional POM elements
that are required for OSS Repository-Hosting.resolveCiFriendliesOnly
Only resolves variables revision, sha1 and changelist.
-
Constructor Summary
Constructors Modifier Constructor Description private
FlattenMode()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description FlattenDescriptor
getDescriptor()
static FlattenMode
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static FlattenMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
minimum
@Deprecated public static final FlattenMode minimum
Deprecated.confusing name, unstable contract.For projects that want to keep alloptional POM elements
.
-
oss
public static final FlattenMode oss
For Open-Source-Software projects that want to keep alloptional POM elements
except forrepositories
andpluginRepositories
.
-
ossrh
public static final FlattenMode ossrh
Keeps alloptional POM elements
that are required for OSS Repository-Hosting.
-
bom
public static final FlattenMode bom
Likeossrh
but additionally keepsdependencyManagement
andproperties
. Especially it will keep thedependencyManagement
as-is without resolving parent influences and import-scoped dependencies. This is useful if your POM represents a BOM (Bill Of Material) and you do not want to deploy it as is (to remove parent and resolve version variables, etc.).
-
defaults
public static final FlattenMode defaults
The default mode that removes alloptional POM elements
exceptrepositories
.
-
clean
public static final FlattenMode clean
Removes alloptional POM elements
.
-
fatjar
public static final FlattenMode fatjar
Removes alloptional POM elements
and dependencies.
-
resolveCiFriendliesOnly
public static final FlattenMode resolveCiFriendliesOnly
Only resolves variables revision, sha1 and changelist. Keeps everything else. See Maven CI Friendly for further details.
-
-
Method Detail
-
values
public static FlattenMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (FlattenMode c : FlattenMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static FlattenMode valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
getDescriptor
public FlattenDescriptor getDescriptor()
- Returns:
- the
FlattenDescriptor
defined by thisFlattenMode
.
-
-