Top Description Fields Constructors Methods
org.springframework.aot

public abstract Class AotDetector

extends Object
Class Inheritance
Imports
org.springframework.core.NativeDetector, .SpringProperties

Utility for determining if AOT-processed optimizations must be used rather than the regular runtime. Strictly for internal use within the framework.
Authors
Stephane Nicoll, Sebastien Deleuze
Since
6.0

Field Summary

Modifier and TypeField and Description
public static final String
AOT_ENABLED

System property that indicates the application should run with AOT generated artifacts.

private static final boolean

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public static boolean

Returns:

whether AOT optimizations must be considered
useGeneratedArtifacts
()

Determine whether AOT optimizations must be considered at runtime.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

AOT_ENABLEDback to summary
public static final String AOT_ENABLED

System property that indicates the application should run with AOT generated artifacts. If such optimizations are not available, it is recommended to throw an exception rather than fall back to the regular runtime behavior.

inNativeImageback to summary
private static final boolean inNativeImage

Constructor Detail

AotDetectorback to summary
public AotDetector()

Method Detail

useGeneratedArtifactsback to summary
public static boolean useGeneratedArtifacts()

Determine whether AOT optimizations must be considered at runtime. This is mandatory in a native image but can be triggered on the JVM using the spring.aot.enabled Spring property.

Returns:boolean

whether AOT optimizations must be considered