Uses of Class
jdk.incubator.foreign.ValueLayout.OfShort
Packages that use ValueLayout.OfShort
Package
Description
Classes to support low-level and efficient foreign memory/function access, directly from Java.
-
Uses of ValueLayout.OfShort in jdk.incubator.foreign
Fields in jdk.incubator.foreign declared as ValueLayout.OfShortModifier and TypeFieldDescriptionstatic final ValueLayout.OfShort
ValueLayout.JAVA_SHORT
A value layout constant whose size is the same as that of a Javashort
, bit alignment set to 8, and byte order set toByteOrder.nativeOrder()
.Methods in jdk.incubator.foreign that return ValueLayout.OfShortMethods in jdk.incubator.foreign with parameters of type ValueLayout.OfShortModifier and TypeMethodDescriptiondefault MemorySegment
SegmentAllocator.allocate
(ValueLayout.OfShort layout, short value) Allocate a memory segment with given layout and initialize it with given short value.default MemorySegment
SegmentAllocator.allocateArray
(ValueLayout.OfShort elementLayout, short[] array) Allocate a memory segment with given layout and initialize it with given short array.short
MemoryAddress.get
(ValueLayout.OfShort layout, long offset) Reads a short from this address and offset with given layout.default short
MemorySegment.get
(ValueLayout.OfShort layout, long offset) Reads a short from this segment and offset with given layout.short
MemoryAddress.getAtIndex
(ValueLayout.OfShort layout, long index) Reads a short from this address and index, scaled by given layout size.default short
MemorySegment.getAtIndex
(ValueLayout.OfShort layout, long index) Reads a short from this segment and index, scaled by given layout size.void
MemoryAddress.set
(ValueLayout.OfShort layout, long offset, short value) Writes a short to this address instance and offset with given layout.default void
MemorySegment.set
(ValueLayout.OfShort layout, long offset, short value) Writes a short to this segment and offset with given layout.void
MemoryAddress.setAtIndex
(ValueLayout.OfShort layout, long index, short value) Writes a short to this address instance and index, scaled by given layout size.default void
MemorySegment.setAtIndex
(ValueLayout.OfShort layout, long index, short value) Writes a short to this segment and index, scaled by given layout size.short[]
MemorySegment.toArray
(ValueLayout.OfShort elementLayout) Copy the contents of this memory segment into a fresh short array.