java.lang.Object
jdk.incubator.foreign.MemoryLayouts
public final class MemoryLayouts extends Object
This class defines useful layout constants. Some of the constants defined in this class are explicit in both
 size and byte order (see 
BITS_64_BE), and can therefore be used to explicitly and unambiguously specify the
 contents of a memory segment. Other constants make implicit byte order assumptions (see
 JAVA_INT); as such, these constants make it easy to work with other serialization-centric APIs,
 such as ByteBuffer.- 
Field SummaryFields Modifier and Type Field Description static ValueLayoutBITS_16_BEA value layout constant with size of two bytes, and byte order set toByteOrder.BIG_ENDIAN.static ValueLayoutBITS_16_LEA value layout constant with size of two bytes, and byte order set toByteOrder.LITTLE_ENDIAN.static ValueLayoutBITS_32_BEA value layout constant with size of four bytes, and byte order set toByteOrder.BIG_ENDIAN.static ValueLayoutBITS_32_LEA value layout constant with size of four bytes, and byte order set toByteOrder.LITTLE_ENDIAN.static ValueLayoutBITS_64_BEA value layout constant with size of eight bytes, and byte order set toByteOrder.BIG_ENDIAN.static ValueLayoutBITS_64_LEA value layout constant with size of eight bytes, and byte order set toByteOrder.LITTLE_ENDIAN.static ValueLayoutBITS_8_BEA value layout constant with size of one byte, and byte order set toByteOrder.BIG_ENDIAN.static ValueLayoutBITS_8_LEA value layout constant with size of one byte, and byte order set toByteOrder.LITTLE_ENDIAN.static ValueLayoutJAVA_BYTEA value layout constant whose size is the same as that of a Javabyte, and byte order set toByteOrder.nativeOrder().static ValueLayoutJAVA_CHARA value layout constant whose size is the same as that of a Javachar, and byte order set toByteOrder.nativeOrder().static ValueLayoutJAVA_DOUBLEA value layout constant whose size is the same as that of a Javadouble, and byte order set toByteOrder.nativeOrder().static ValueLayoutJAVA_FLOATA value layout constant whose size is the same as that of a Javafloat, and byte order set toByteOrder.nativeOrder().static ValueLayoutJAVA_INTA value layout constant whose size is the same as that of a Javaint, and byte order set toByteOrder.nativeOrder().static ValueLayoutJAVA_LONGA value layout constant whose size is the same as that of a Javalong, and byte order set toByteOrder.nativeOrder().static ValueLayoutJAVA_SHORTA value layout constant whose size is the same as that of a Javashort, and byte order set toByteOrder.nativeOrder().static MemoryLayoutPAD_16A padding layout constant with size of two bytes.static MemoryLayoutPAD_32A padding layout constant with size of four bytes.static MemoryLayoutPAD_64A padding layout constant with size of eight bytes.static MemoryLayoutPAD_8A padding layout constant with size of one byte.
- 
Method Summary
- 
Field Details- 
BITS_8_LEA value layout constant with size of one byte, and byte order set toByteOrder.LITTLE_ENDIAN.
- 
BITS_16_LEA value layout constant with size of two bytes, and byte order set toByteOrder.LITTLE_ENDIAN.
- 
BITS_32_LEA value layout constant with size of four bytes, and byte order set toByteOrder.LITTLE_ENDIAN.
- 
BITS_64_LEA value layout constant with size of eight bytes, and byte order set toByteOrder.LITTLE_ENDIAN.
- 
BITS_8_BEA value layout constant with size of one byte, and byte order set toByteOrder.BIG_ENDIAN.
- 
BITS_16_BEA value layout constant with size of two bytes, and byte order set toByteOrder.BIG_ENDIAN.
- 
BITS_32_BEA value layout constant with size of four bytes, and byte order set toByteOrder.BIG_ENDIAN.
- 
BITS_64_BEA value layout constant with size of eight bytes, and byte order set toByteOrder.BIG_ENDIAN.
- 
PAD_8A padding layout constant with size of one byte.
- 
PAD_16A padding layout constant with size of two bytes.
- 
PAD_32A padding layout constant with size of four bytes.
- 
PAD_64A padding layout constant with size of eight bytes.
- 
JAVA_BYTEA value layout constant whose size is the same as that of a Javabyte, and byte order set toByteOrder.nativeOrder().
- 
JAVA_CHARA value layout constant whose size is the same as that of a Javachar, and byte order set toByteOrder.nativeOrder().
- 
JAVA_SHORTA value layout constant whose size is the same as that of a Javashort, and byte order set toByteOrder.nativeOrder().
- 
JAVA_INTA value layout constant whose size is the same as that of a Javaint, and byte order set toByteOrder.nativeOrder().
- 
JAVA_LONGA value layout constant whose size is the same as that of a Javalong, and byte order set toByteOrder.nativeOrder().
- 
JAVA_FLOATA value layout constant whose size is the same as that of a Javafloat, and byte order set toByteOrder.nativeOrder().
- 
JAVA_DOUBLEA value layout constant whose size is the same as that of a Javadouble, and byte order set toByteOrder.nativeOrder().
 
-