Uses of Interface
jdk.incubator.foreign.MemoryLayout
| Package | Description |
|---|---|
| jdk.incubator.foreign |
Classes to support low-level, safe and efficient memory access.
|
-
Uses of MemoryLayout in jdk.incubator.foreign
Classes in jdk.incubator.foreign that implement MemoryLayout Modifier and Type Class Description classGroupLayoutA group layout is used to combine together multiple member layouts.classSequenceLayoutA sequence layout.classValueLayoutA value layout.Fields in jdk.incubator.foreign declared as MemoryLayout Modifier and Type Field Description static MemoryLayoutMemoryLayouts. PAD_16A padding layout constant with size of two bytes.static MemoryLayoutMemoryLayouts. PAD_32A padding layout constant with size of four bytes.static MemoryLayoutMemoryLayouts. PAD_64A padding layout constant with size of eight bytes.static MemoryLayoutMemoryLayouts. PAD_8A padding layout constant with size of one byte.Methods in jdk.incubator.foreign that return MemoryLayout Modifier and Type Method Description MemoryLayoutSequenceLayout. elementLayout()Returns the element layout associated with this sequence layout.default MemoryLayoutMemoryLayout. map(UnaryOperator<MemoryLayout> op, MemoryLayout.PathElement... elements)Creates a transformed copy of this layout where a selected layout, from a path rooted in this layout, is replaced with the result of applying the given operation.static MemoryLayoutMemoryLayout. ofPaddingBits(long size)Create a new padding layout with given size.default MemoryLayoutMemoryLayout. select(MemoryLayout.PathElement... elements)Selects the layout from a path rooted in this layout.MemoryLayoutMemoryLayout. withBitAlignment(long bitAlignment)Creates a new layout which features the desired alignment constraint.MemoryLayoutMemoryLayout. withName(String name)Creates a new layout which features the desired layout name.Methods in jdk.incubator.foreign that return types with arguments of type MemoryLayout Modifier and Type Method Description Optional<? extends DynamicConstantDesc<? extends MemoryLayout>>MemoryLayout. describeConstable()List<MemoryLayout>GroupLayout. memberLayouts()Returns the member layouts associated with this group.Methods in jdk.incubator.foreign with parameters of type MemoryLayout Modifier and Type Method Description static MemorySegmentMemorySegment. allocateNative(MemoryLayout layout)Creates a new native memory segment that models a newly allocated block of off-heap memory with given layout.static SequenceLayoutMemoryLayout. ofSequence(long elementCount, MemoryLayout elementLayout)Create a new sequence layout with given element layout and element count.static SequenceLayoutMemoryLayout. ofSequence(MemoryLayout elementLayout)Create a new sequence layout, with unbounded element count and given element layout.static GroupLayoutMemoryLayout. ofStruct(MemoryLayout... elements)Create a new struct group layout with given member layouts.static GroupLayoutMemoryLayout. ofUnion(MemoryLayout... elements)Create a new union group layout with given member layouts.Method parameters in jdk.incubator.foreign with type arguments of type MemoryLayout Modifier and Type Method Description default MemoryLayoutMemoryLayout. map(UnaryOperator<MemoryLayout> op, MemoryLayout.PathElement... elements)Creates a transformed copy of this layout where a selected layout, from a path rooted in this layout, is replaced with the result of applying the given operation.