Uses of Interface
java.lang.foreign.SegmentAllocator
Package
Description
Provides low-level access to memory and functions outside the Java runtime.
-
Uses of SegmentAllocator in java.lang.foreign
Modifier and TypeInterfaceDescriptioninterface
An arena controls the lifecycle of native memory segments, providing both flexible allocation and timely deallocation.Modifier and TypeMethodDescriptionstatic SegmentAllocator
SegmentAllocator.prefixAllocator
(MemorySegment segment) Returns a segment allocator that responds to allocation requests by recycling a single segment.static SegmentAllocator
SegmentAllocator.slicingAllocator
(MemorySegment segment) Returns a segment allocator that responds to allocation requests by returning consecutive slices obtained from the provided segment.