Package org.apache.maven.api.settings
Class ActivationOS
java.lang.Object
org.apache.maven.api.settings.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
Nested ClassesModifier and TypeClassDescriptionstatic classBuilder class used to create ActivationOS instances. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedActivationOS(ActivationOS.Builder builder) Constructor for this class, to be called from its subclasses andActivationOS.Builder. -
Method Summary
Modifier and TypeMethodDescriptiongetArch()The architecture of the OS to be used to activate a profile.The general family of the OS to be used to activate a profile (e.g.Gets the input location that caused this model to be read.getLocation(Object key) Gets the location of the specified field in the input source.Gets the keys of the locations of the input source.getName()The name of the OS to be used to activate a profile.The version of the OS to be used to activate a profile.static ActivationOS.BuilderCreates a newActivationOSbuilder instance.static ActivationOS.BuildernewBuilder(boolean withDefaults) Creates a newActivationOSbuilder instance using default values or not.static ActivationOS.BuildernewBuilder(ActivationOS from) Creates a newActivationOSbuilder instance using the specified object as a basis.static ActivationOS.BuildernewBuilder(ActivationOS from, boolean forceCopy) Creates a newActivationOSbuilder instance using the specified object as a basis.static ActivationOSCreates a newActivationOSinstance.static ActivationOSnewInstance(boolean withDefaults) Creates a newActivationOSinstance using default values or not.with()Creates a new builder with this object as the basis.Creates a newActivationOSinstance using the specified arch.withFamily(String family) Creates a newActivationOSinstance using the specified family.Creates a newActivationOSinstance using the specified name.withVersion(String version) Creates a newActivationOSinstance using the specified version.
-
Constructor Details
-
ActivationOS
Constructor for this class, to be called from its subclasses andActivationOS.Builder.- See Also:
-
-
Method Details
-
getName
The name of the OS to be used to activate a profile.- Returns:
- a
String
-
getFamily
The general family of the OS to be used to activate a profile (e.g. 'windows')- Returns:
- a
String
-
getArch
The architecture of the OS to be used to activate a profile.- Returns:
- a
String
-
getVersion
The version of the OS to be used to activate a profile.- Returns:
- a
String
-
getLocation
Gets the location of the specified field in the input source.- Specified by:
getLocationin interfaceInputLocationTracker
-
getLocationKeys
Gets the keys of the locations of the input source. -
getImportedFrom
Gets the input location that caused this model to be read. -
with
Creates a new builder with this object as the basis.- Returns:
- a
Builder
-
withName
Creates a newActivationOSinstance using the specified name.- Parameters:
name- the newStringto use- Returns:
- a
ActivationOSwith the specified name
-
withFamily
Creates a newActivationOSinstance using the specified family.- Parameters:
family- the newStringto use- Returns:
- a
ActivationOSwith the specified family
-
withArch
Creates a newActivationOSinstance using the specified arch.- Parameters:
arch- the newStringto use- Returns:
- a
ActivationOSwith the specified arch
-
withVersion
Creates a newActivationOSinstance using the specified version.- Parameters:
version- the newStringto use- Returns:
- a
ActivationOSwith the specified version
-
newInstance
Creates a newActivationOSinstance. Equivalent tonewInstance(true).- Returns:
- a new
ActivationOS - See Also:
-
newInstance
Creates a newActivationOSinstance 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 newActivationOSbuilder instance. Equivalent tonewBuilder(true).- Returns:
- a new
Builder - See Also:
-
newBuilder
Creates a newActivationOSbuilder instance using default values or not.- Parameters:
withDefaults- the boolean indicating whether default values should be used- Returns:
- a new
Builder
-
newBuilder
Creates a newActivationOSbuilder instance using the specified object as a basis. Equivalent tonewBuilder(from, false).- Parameters:
from- theActivationOSinstance to use as a basis- Returns:
- a new
Builder
-
newBuilder
Creates a newActivationOSbuilder instance using the specified object as a basis.- Parameters:
from- theActivationOSinstance to use as a basisforceCopy- the boolean indicating if a copy should be forced- Returns:
- a new
Builder
-