Package org.apache.maven.api.model
Class ActivationOS
java.lang.Object
org.apache.maven.api.model.ActivationOS
- All Implemented Interfaces:
Serializable
,InputLocationTracker
@Experimental
@Generated
@ThreadSafe
@Immutable
public class ActivationOS
extends Object
implements Serializable, InputLocationTracker
This is an activator which will detect an operating system's attributes in order
to activate its profile.
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Builder class used to create ActivationOS instances. -
Method Summary
Modifier and TypeMethodDescriptiongetArch()
The architecture of the operating system to be used to activate the profile.The general family of the OS to be used to activate the profile, such aswindows
orunix
.getLocation
(Object key) Gets the location of the specified field in the input source.getName()
The name of the operating system to be used to activate the profile.The version of the operating system to be used to activate the profile.static ActivationOS.Builder
Creates a newActivationOS
builder instance.static ActivationOS.Builder
newBuilder
(boolean withDefaults) Creates a newActivationOS
builder instance using default values or not.static ActivationOS.Builder
newBuilder
(ActivationOS from) Creates a newActivationOS
builder instance using the specified object as a basis.static ActivationOS.Builder
newBuilder
(ActivationOS from, boolean forceCopy) Creates a newActivationOS
builder instance using the specified object as a basis.static ActivationOS
Creates a newActivationOS
instance.static ActivationOS
newInstance
(boolean withDefaults) Creates a newActivationOS
instance using default values or not.with()
Creates a new builder with this object as the basis.Creates a newActivationOS
instance using the specified arch.withFamily
(String family) Creates a newActivationOS
instance using the specified family.Creates a newActivationOS
instance using the specified name.withVersion
(String version) Creates a newActivationOS
instance using the specified version.
-
Method Details
-
getName
The name of the operating system to be used to activate the profile. This must be an exact match of the${os.name}
Java property, such asWindows XP
.- Returns:
- a
String
-
getFamily
The general family of the OS to be used to activate the profile, such aswindows
orunix
.- Returns:
- a
String
-
getArch
The architecture of the operating system to be used to activate the profile.- Returns:
- a
String
-
getVersion
The version of the operating system to be used to activate the profile.- Returns:
- a
String
-
getLocation
Gets the location of the specified field in the input source.- Specified by:
getLocation
in interfaceInputLocationTracker
-
with
Creates a new builder with this object as the basis.- Returns:
- a
Builder
-
withName
Creates a newActivationOS
instance using the specified name.- Parameters:
name
- the newString
to use- Returns:
- a
ActivationOS
with the specified name
-
withFamily
Creates a newActivationOS
instance using the specified family.- Parameters:
family
- the newString
to use- Returns:
- a
ActivationOS
with the specified family
-
withArch
Creates a newActivationOS
instance using the specified arch.- Parameters:
arch
- the newString
to use- Returns:
- a
ActivationOS
with the specified arch
-
withVersion
Creates a newActivationOS
instance using the specified version.- Parameters:
version
- the newString
to use- Returns:
- a
ActivationOS
with the specified version
-
newInstance
Creates a newActivationOS
instance. Equivalent tonewInstance(true)
.- Returns:
- a new
ActivationOS
- See Also:
-
newInstance
Creates a newActivationOS
instance using default values or not. Equivalent tonewBuilder(withDefaults).build()
.- Parameters:
withDefaults
- the boolean indicating whether default values should be used- Returns:
- a new
ActivationOS
-
newBuilder
Creates a newActivationOS
builder instance. Equivalent tonewBuilder(true)
.- Returns:
- a new
Builder
- See Also:
-
newBuilder
Creates a newActivationOS
builder instance using default values or not.- Parameters:
withDefaults
- the boolean indicating whether default values should be used- Returns:
- a new
Builder
-
newBuilder
Creates a newActivationOS
builder instance using the specified object as a basis. Equivalent tonewBuilder(from, false)
.- Parameters:
from
- theActivationOS
instance to use as a basis- Returns:
- a new
Builder
-
newBuilder
Creates a newActivationOS
builder instance using the specified object as a basis.- Parameters:
from
- theActivationOS
instance to use as a basisforceCopy
- the boolean indicating if a copy should be forced- Returns:
- a new
Builder
-