APIdia Launch Partner
Top Description Inners Constructors Methods
jdk.internal.foreign.layout

public final Class ValueLayouts

extends Object
Class Inheritance
Annotations
@ValueBased
Imports
jdk.internal.ValueBased, jdk.internal.foreign.LayoutPath, .Utils, jdk.internal.misc.Unsafe, jdk.internal.reflect.CallerSensitive, .Reflection, jdk.internal.vm.annotation.ForceInline, .Stable, java.lang.foreign.AddressLayout, .MemoryLayout, .MemorySegment, .ValueLayout, java.lang.invoke.VarHandle, java.nio.ByteOrder, java.util.Objects, .Optional

A value layout. A value layout is used to model the memory layout associated with values of basic data types, such as integral types (either signed or unsigned) and floating-point types. Each value layout has a size, an alignment (expressed in bytes), a byte order, and a carrier, that is, the Java type that should be used when accessing a memory region using the value layout.

This class defines useful value layout constants for Java primitive types and addresses. The layout constants in this class make implicit alignment and byte-ordering assumption: all layout constants in this class are byte-aligned, and their byte order is set to the platform default, thus making it easy to work with other APIs, such as arrays and java.nio.ByteBuffer.

Implementation Specification

This class and its subclasses are immutable, thread-safe and value-based.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv abstract static class
public static class
public static class
public static class
public static class
public static class
public static class
public static class
public static class
public static class

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static ValueLayout

Returns:

a value layout with the given Java carrier and byte-order.
valueLayout
(Class<?>
the value layout carrier.
carrier
,
ByteOrder
the value layout's byte order.
order
)

Creates a value layout of given Java carrier and byte order.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait