Package org.apache.lucene.util
Class Constants
- java.lang.Object
-
- org.apache.lucene.util.Constants
-
public final class Constants extends Object
Some useful constants.
-
-
Field Summary
Fields Modifier and Type Field Description static booleanFREE_BSDTrue iff running on FreeBSDstatic booleanHAS_FAST_SCALAR_FMAtrue iff we know FMA has faster throughput than separate mul/add.static booleanHAS_FAST_VECTOR_FMAtrue iff we know VFMA has faster throughput than separate vmul/vadd.static booleanIS_CLIENT_VMTrue iff the Java runtime is a client runtime and C2 compiler is not enabled.static booleanIS_HOTSPOT_VMTrue iff the Java VM is based on Hotspot and has the Hotspot MX bean readable by Lucene.static booleanIS_JVMCI_VMTrue if jvmci is enabled (e.g.static StringJAVA_VENDORThe value ofSystem.getProperty("java.vendor").static StringJAVA_VERSIONDeprecated.To detect Java versions useRuntime.version()static booleanJRE_IS_64BITTrue iff running on a 64bit JVMstatic booleanJRE_IS_MINIMUM_JAVA11Deprecated.This constant is useless and alwaystrue.static booleanJRE_IS_MINIMUM_JAVA8Deprecated.This constant is useless and alwaystrue.static booleanJRE_IS_MINIMUM_JAVA9Deprecated.This constant is useless and alwaystrue.static StringJVM_NAMEJVM vendor name.static StringJVM_SPEC_VERSIONDeprecated.To detect Java versions useRuntime.version()static StringJVM_VENDORJVM vendor info.static StringJVM_VERSIONDeprecated.To detect Java versions useRuntime.version()static booleanLINUXTrue iff running on Linux.static booleanMAC_OS_XTrue iff running on Mac OS Xstatic StringOS_ARCHThe value ofSystem.getProperty("os.arch").static StringOS_NAMEThe value ofSystem.getProperty("os.name").static StringOS_VERSIONThe value ofSystem.getProperty("os.version").static booleanSUN_OSTrue iff running on SunOS.static booleanWINDOWSTrue iff running on Windows.
-
-
-
Field Detail
-
JVM_VENDOR
public static final String JVM_VENDOR
JVM vendor info.
-
JVM_NAME
public static final String JVM_NAME
JVM vendor name.
-
JVM_VERSION
@Deprecated public static final String JVM_VERSION
Deprecated.To detect Java versions useRuntime.version()Get the full version string of the current runtime.
-
JVM_SPEC_VERSION
@Deprecated public static final String JVM_SPEC_VERSION
Deprecated.To detect Java versions useRuntime.version()Gets the specification version of the current runtime. This is the feature version converted to String.- See Also:
Runtime.Version.feature()
-
JAVA_VERSION
@Deprecated public static final String JAVA_VERSION
Deprecated.To detect Java versions useRuntime.version()The value ofSystem.getProperty("java.version").
-
OS_NAME
public static final String OS_NAME
The value ofSystem.getProperty("os.name"). *
-
LINUX
public static final boolean LINUX
True iff running on Linux.
-
WINDOWS
public static final boolean WINDOWS
True iff running on Windows.
-
SUN_OS
public static final boolean SUN_OS
True iff running on SunOS.
-
MAC_OS_X
public static final boolean MAC_OS_X
True iff running on Mac OS X
-
FREE_BSD
public static final boolean FREE_BSD
True iff running on FreeBSD
-
OS_ARCH
public static final String OS_ARCH
The value ofSystem.getProperty("os.arch").
-
OS_VERSION
public static final String OS_VERSION
The value ofSystem.getProperty("os.version").
-
JAVA_VENDOR
public static final String JAVA_VENDOR
The value ofSystem.getProperty("java.vendor").
-
IS_CLIENT_VM
public static final boolean IS_CLIENT_VM
True iff the Java runtime is a client runtime and C2 compiler is not enabled.
-
IS_HOTSPOT_VM
public static final boolean IS_HOTSPOT_VM
True iff the Java VM is based on Hotspot and has the Hotspot MX bean readable by Lucene.
-
IS_JVMCI_VM
public static final boolean IS_JVMCI_VM
True if jvmci is enabled (e.g. graalvm)
-
JRE_IS_64BIT
public static final boolean JRE_IS_64BIT
True iff running on a 64bit JVM
-
HAS_FAST_VECTOR_FMA
public static final boolean HAS_FAST_VECTOR_FMA
true iff we know VFMA has faster throughput than separate vmul/vadd.
-
HAS_FAST_SCALAR_FMA
public static final boolean HAS_FAST_SCALAR_FMA
true iff we know FMA has faster throughput than separate mul/add.
-
JRE_IS_MINIMUM_JAVA8
@Deprecated public static final boolean JRE_IS_MINIMUM_JAVA8
Deprecated.This constant is useless and alwaystrue. To detect Java versions useRuntime.version()Always true.- See Also:
- Constant Field Values
-
JRE_IS_MINIMUM_JAVA9
@Deprecated public static final boolean JRE_IS_MINIMUM_JAVA9
Deprecated.This constant is useless and alwaystrue. To detect Java versions useRuntime.version()Always true.- See Also:
- Constant Field Values
-
JRE_IS_MINIMUM_JAVA11
@Deprecated public static final boolean JRE_IS_MINIMUM_JAVA11
Deprecated.This constant is useless and alwaystrue. To detect Java versions useRuntime.version()Always true.- See Also:
- Constant Field Values
-
-