Class Requirement
java.lang.Object
org.apache.maven.api.plugin.descriptor.Requirement
- All Implemented Interfaces:
Serializable
@Experimental
@Generated
@ThreadSafe
@Immutable
public class Requirement
extends Object
implements Serializable
Describes a component requirement.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classBuilder class used to create Requirement instances. -
Method Summary
Modifier and TypeMethodDescriptionThe field name which has this requirement.getRole()static Requirement.BuilderCreates a newRequirementbuilder instance.static Requirement.BuildernewBuilder(boolean withDefaults) Creates a newRequirementbuilder instance using default values or not.static Requirement.BuildernewBuilder(Requirement from) Creates a newRequirementbuilder instance using the specified object as a basis.static Requirement.BuildernewBuilder(Requirement from, boolean forceCopy) Creates a newRequirementbuilder instance using the specified object as a basis.static RequirementCreates a newRequirementinstance.static RequirementnewInstance(boolean withDefaults) Creates a newRequirementinstance using default values or not.with()Creates a new builder with this object as the basis.withFieldName(String fieldName) Creates a newRequirementinstance using the specified fieldName.Creates a newRequirementinstance using the specified role.withRoleHint(String roleHint) Creates a newRequirementinstance using the specified roleHint.
-
Method Details
-
getRole
- Returns:
- a
String
-
getRoleHint
- Returns:
- a
String
-
getFieldName
The field name which has this requirement.- Returns:
- a
String
-
with
Creates a new builder with this object as the basis.- Returns:
- a
Builder
-
withRole
Creates a newRequirementinstance using the specified role.- Parameters:
role- the newStringto use- Returns:
- a
Requirementwith the specified role
-
withRoleHint
Creates a newRequirementinstance using the specified roleHint.- Parameters:
roleHint- the newStringto use- Returns:
- a
Requirementwith the specified roleHint
-
withFieldName
Creates a newRequirementinstance using the specified fieldName.- Parameters:
fieldName- the newStringto use- Returns:
- a
Requirementwith the specified fieldName
-
newInstance
Creates a newRequirementinstance. Equivalent tonewInstance(true).- Returns:
- a new
Requirement - See Also:
-
newInstance
Creates a newRequirementinstance using default values or not. Equivalent tonewBuilder(withDefaults).build().- Parameters:
withDefaults- the boolean indicating whether default values should be used- Returns:
- a new
Requirement
-
newBuilder
Creates a newRequirementbuilder instance. Equivalent tonewBuilder(true).- Returns:
- a new
Builder - See Also:
-
newBuilder
Creates a newRequirementbuilder instance using default values or not.- Parameters:
withDefaults- the boolean indicating whether default values should be used- Returns:
- a new
Builder
-
newBuilder
Creates a newRequirementbuilder instance using the specified object as a basis. Equivalent tonewBuilder(from, false).- Parameters:
from- theRequirementinstance to use as a basis- Returns:
- a new
Builder
-
newBuilder
Creates a newRequirementbuilder instance using the specified object as a basis.- Parameters:
from- theRequirementinstance to use as a basisforceCopy- the boolean indicating if a copy should be forced- Returns:
- a new
Builder
-