# Uses of Class
jdk.incubator.foreign.ValueLayout

Packages that use ValueLayout
Package
Description
jdk.incubator.foreign
Classes to support low-level and efficient foreign memory/function access, directly from Java.

## Uses of ValueLayout in jdk.incubator.foreign

Subclasses of ValueLayout in jdk.incubator.foreign
Modifier and Type
Class
Description
`static final class`
`ValueLayout.OfAddress`
A value layout whose carrier is `MemoryAddress.class`.
`static final class`
`ValueLayout.OfBoolean`
A value layout whose carrier is `boolean.class`.
`static final class`
`ValueLayout.OfByte`
A value layout whose carrier is `byte.class`.
`static final class`
`ValueLayout.OfChar`
A value layout whose carrier is `char.class`.
`static final class`
`ValueLayout.OfDouble`
A value layout whose carrier is `double.class`.
`static final class`
`ValueLayout.OfFloat`
A value layout whose carrier is `float.class`.
`static final class`
`ValueLayout.OfInt`
A value layout whose carrier is `int.class`.
`static final class`
`ValueLayout.OfLong`
A value layout whose carrier is `long.class`.
`static final class`
`ValueLayout.OfShort`
A value layout whose carrier is `short.class`.
Methods in jdk.incubator.foreign that return ValueLayout
Modifier and Type
Method
Description
`static ValueLayout`
MemoryLayout.`valueLayout(Class<?> carrier, ByteOrder order)`
Creates a value layout of given Java carrier and byte order.
`ValueLayout`
ValueLayout.`withBitAlignment(long alignmentBits)`
Creates a new layout which features the desired alignment constraint.
`ValueLayout`
ValueLayout.`withName(String name)`
Creates a new layout which features the desired layout name.
`ValueLayout`
ValueLayout.`withOrder(ByteOrder order)`
Returns a new value layout with given byte order.
Methods in jdk.incubator.foreign that return types with arguments of type ValueLayout
Modifier and Type
Method
Description
`Optional<DynamicConstantDesc<ValueLayout>>`
ValueLayout.`describeConstable()`
Methods in jdk.incubator.foreign with parameters of type ValueLayout
Modifier and Type
Method
Description
`static void`
MemorySegment.`copy(Object srcArray, int srcIndex, MemorySegment dstSegment, ValueLayout dstLayout, long dstOffset, int elementCount)`
Copies a number of elements from a source array to a destination segment, starting at a given array index, and a given segment offset (expressed in bytes), using the given destination element layout.
`static void`
MemorySegment.`copy(MemorySegment srcSegment, ValueLayout srcLayout, long srcOffset, Object dstArray, int dstIndex, int elementCount)`
Copies a number of elements from a source segment to a destination array, starting at a given segment offset (expressed in bytes), and a given array index, using the given source element layout.
`static void`
MemorySegment.`copy(MemorySegment srcSegment, ValueLayout srcElementLayout, long srcOffset, MemorySegment dstSegment, ValueLayout dstElementLayout, long dstOffset, long elementCount)`
Performs a bulk copy from source segment to destination segment.
`static VarHandle`
MemoryHandles.`varHandle(ValueLayout layout)`
Creates a memory access var handle from given value layout.