Class BaselineJavaVersionExtension
- java.lang.Object
-
- com.palantir.baseline.plugins.javaversions.BaselineJavaVersionExtension
-
public class BaselineJavaVersionExtension extends java.lang.ObjectExtension namedjavaVersionused to set the target and runtime java versions used for a single project.
-
-
Constructor Summary
Constructors Constructor Description BaselineJavaVersionExtension(org.gradle.api.Project project)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidlibrary()org.gradle.api.provider.Property<java.lang.Boolean>overrideLibraryAutoDetection()Overrides auto-detection if a value is present to force this module to be a library (true) or a distributionfalse).org.gradle.api.provider.Property<ChosenJavaVersion>runtime()RuntimeChosenJavaVersionfor testing and distributions.voidsetRuntime(int value)voidsetRuntime(java.lang.String value)voidsetTarget(int value)voidsetTarget(java.lang.String value)org.gradle.api.provider.Property<ChosenJavaVersion>target()TargetChosenJavaVersionfor compilation.
-
-
-
Method Detail
-
target
public final org.gradle.api.provider.Property<ChosenJavaVersion> target()
TargetChosenJavaVersionfor compilation. Also determines whether the `--enable-preview` flag should be used for compilation, producing bytecode with a minor version of '65535'. Unlike normal bytecode, this bytecode cannot be run by a higher version of Java that it was compiled by.
-
setTarget
public final void setTarget(int value)
-
setTarget
public final void setTarget(java.lang.String value)
-
runtime
public final org.gradle.api.provider.Property<ChosenJavaVersion> runtime()
RuntimeChosenJavaVersionfor testing and distributions.
-
setRuntime
public final void setRuntime(int value)
-
setRuntime
public final void setRuntime(java.lang.String value)
-
overrideLibraryAutoDetection
public final org.gradle.api.provider.Property<java.lang.Boolean> overrideLibraryAutoDetection()
Overrides auto-detection if a value is present to force this module to be a library (true) or a distributionfalse).
-
library
public final void library()
-
-