Package org.gradle.nativeplatform
Class OperatingSystemFamily
- java.lang.Object
-
- org.gradle.nativeplatform.OperatingSystemFamily
-
- All Implemented Interfaces:
Named
public abstract class OperatingSystemFamily extends java.lang.Object implements Named
Represents the operating system of a configuration. Typical operating system include Windows, Linux, and macOS. This interface allows the user to customize operating systems by implementing this interface.- Since:
- 5.1
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.gradle.api.Named
Named.Namer
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringLINUXThe Linux operating system family.static java.lang.StringMACOSThe macOS operating system family.static Attribute<OperatingSystemFamily>OPERATING_SYSTEM_ATTRIBUTEstatic java.lang.StringWINDOWSThe Windows operating system family.
-
Constructor Summary
Constructors Constructor Description OperatingSystemFamily()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract java.lang.StringgetName()The object's name.booleanisLinux()Is this the Linux operating system family?booleanisMacOs()Is this the macOS operating system family?booleanisWindows()Is this the Windows operating system family?
-
-
-
Field Detail
-
OPERATING_SYSTEM_ATTRIBUTE
public static final Attribute<OperatingSystemFamily> OPERATING_SYSTEM_ATTRIBUTE
-
WINDOWS
public static final java.lang.String WINDOWS
The Windows operating system family.- See Also:
- Constant Field Values
-
LINUX
public static final java.lang.String LINUX
The Linux operating system family.- See Also:
- Constant Field Values
-
MACOS
public static final java.lang.String MACOS
The macOS operating system family.- See Also:
- Constant Field Values
-
-
Method Detail
-
getName
@Input public abstract java.lang.String getName()
The object's name.Must be constant for the life of the object.
-
isWindows
public boolean isWindows()
Is this the Windows operating system family?
-
isLinux
public boolean isLinux()
Is this the Linux operating system family?
-
isMacOs
public boolean isMacOs()
Is this the macOS operating system family?
-
-