Class JdkSpecOverride
java.lang.Object
com.dua3.gradle.jdkprovider.plugin.JdkSpecOverride
Configuration for a specific JDK.
-
Constructor Summary
ConstructorsConstructorDescriptionJdkSpecOverride(String name, org.gradle.api.model.ObjectFactory objects) Constructs an instance ofJdkSpecOverridewith the specified name and object factory. -
Method Summary
Modifier and TypeMethodDescriptionorg.gradle.api.provider.Property<SystemArchitecture> getArch()Retrieves the property representing the system architecture configuration.org.gradle.api.provider.Property<Boolean> Retrieves the property indicating whether JavaFX is bundled with the JDK.org.gradle.api.provider.Provider<org.gradle.api.file.Directory> Read-only provider for the resolved JDK home directory of this override.org.gradle.api.provider.Provider<JdkSpec> Read-only provider for the resolved JDK specification of this override.org.gradle.api.provider.Property<Integer> Retrieves the Java language version used for compilation with this JDK override.getName()Retrieves the name of this JDK specification override configuration.org.gradle.api.provider.Property<Boolean> Retrieves the property indicating whether native image capabilities are supported.org.gradle.api.provider.Property<OSFamily> getOs()Retrieves the operating system family property for this configuration.org.gradle.api.provider.Property<org.gradle.jvm.toolchain.JvmVendorSpec> Returns the property representing the JDK vendor specification.org.gradle.api.provider.Property<Object> Retrieves the version property of this JDK specification override.voidsetLangVersion(int langVersion) Sets the Java language version used for compilation with this JDK override.voidsetVersion(int version) Sets the version of the JDK specification override.voidsetVersion(String version) Sets the version property for the JDK specification override.
-
Constructor Details
-
JdkSpecOverride
Constructs an instance ofJdkSpecOverridewith the specified name and object factory.- Parameters:
name- the name of the JDK specification override, used to uniquely identify this configurationobjects- the object factory used to create property instances for this configuration
-
-
Method Details
-
getName
Retrieves the name of this JDK specification override configuration.- Returns:
- the name of the JDK specification override
-
getOs
Retrieves the operating system family property for this configuration.- Returns:
- the
Propertyrepresenting the operating system family associated with this configuration.
-
getArch
Retrieves the property representing the system architecture configuration.- Returns:
- a
Property<SystemArchitecture>instance that holds the value of the system architecture
-
getVersion
Retrieves the version property of this JDK specification override.- Returns:
- the
Propertyrepresenting the version, which can hold various types of values such as an integer or a string.
-
setVersion
public void setVersion(int version) Sets the version of the JDK specification override.- Parameters:
version- the version of the JDK specification as an integer
-
setVersion
Sets the version property for the JDK specification override.- Parameters:
version- the version value to be set, represented as aString
-
getLangVersion
Retrieves the Java language version used for compilation with this JDK override.- Returns:
- a property containing the Java language version used for compilation
-
setLangVersion
public void setLangVersion(int langVersion) Sets the Java language version used for compilation with this JDK override.- Parameters:
langVersion- the value to pass tojavac --release
-
getVendor
public org.gradle.api.provider.Property<org.gradle.jvm.toolchain.JvmVendorSpec> getVendor()Returns the property representing the JDK vendor specification.- Returns:
- a property encapsulating the vendor specification for the JDK
-
getNativeImageCapable
Retrieves the property indicating whether native image capabilities are supported.- Returns:
- a
Propertyof typeBooleanrepresenting the native image capability status.
-
getJavaFxBundled
Retrieves the property indicating whether JavaFX is bundled with the JDK.- Returns:
- a property that contains a boolean value, where
trueindicates that JavaFX is bundled, andfalseindicates it is not bundled.
-
getJdkHome
public org.gradle.api.provider.Provider<org.gradle.api.file.Directory> getJdkHome()Read-only provider for the resolved JDK home directory of this override.- Returns:
- a provider for the resolved JDK home directory
-
getJdkSpec
Read-only provider for the resolved JDK specification of this override.- Returns:
- a provider for the resolved JDK specification
-