Module java.base

Interface UnionLayout

All Superinterfaces:
GroupLayoutPREVIEW, MemoryLayoutPREVIEW

public sealed interface UnionLayout extends GroupLayoutPREVIEW
UnionLayout is a preview API of the Java platform.
Programs can only use UnionLayout when preview features are enabled.
Preview features may be removed in a future release, or upgraded to permanent features of the Java platform.
A union layout where member layouts are laid out at the same starting offset (see MemoryLayout.unionLayout(MemoryLayout...)PREVIEW).
Implementation Requirements:
Implementing classes are immutable, thread-safe and value-based.