Package io.quarkus.runtime
Enum ImageMode
- java.lang.Object
-
- java.lang.Enum<ImageMode>
-
- io.quarkus.runtime.ImageMode
-
- All Implemented Interfaces:
Serializable
,Comparable<ImageMode>
public enum ImageMode extends Enum<ImageMode>
The image execution mode of the application.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description JVM
The image mode which indicates that the application is running in a standard JVM.NATIVE_BUILD
The image mode which indicates that the application is currently executing the build phase of a native static image.NATIVE_RUN
The image mode which indicates that the application is a native static image which is currently running on a target system.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImageMode
current()
Get the current image mode.boolean
isNativeImage()
Determine whether the application image is a native static image.static ImageMode
valueOf(String name)
Returns the enum constant of this type with the specified name.static ImageMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
JVM
public static final ImageMode JVM
The image mode which indicates that the application is running in a standard JVM.
-
NATIVE_BUILD
public static final ImageMode NATIVE_BUILD
The image mode which indicates that the application is currently executing the build phase of a native static image.
-
NATIVE_RUN
public static final ImageMode NATIVE_RUN
The image mode which indicates that the application is a native static image which is currently running on a target system.
-
-
Method Detail
-
values
public static ImageMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ImageMode c : ImageMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ImageMode valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
isNativeImage
public boolean isNativeImage()
Determine whether the application image is a native static image.- Returns:
true
if the application image is a native static image, orfalse
otherwise
-
current
public static ImageMode current()
Get the current image mode. Note that it is possible for the image mode to change during the lifetime of an application.- Returns:
- the image mode (not
null
)
-
-