Class mln_json_object
java.lang.Object
org.maplibre.nativeffi.internal.c.mln_json_object
struct mln_json_object {
const mln_json_member *members;
size_t member_count;
}
-
Method Summary
Modifier and TypeMethodDescriptionstatic MemorySegmentallocate(SegmentAllocator allocator) Allocate a segment of sizelayout().byteSize()usingallocatorstatic MemorySegmentallocateArray(long elementCount, SegmentAllocator allocator) Allocate an array of sizeelementCountusingallocator.static MemorySegmentasSlice(MemorySegment array, long index) Obtains a slice ofarrayParamwhich selects the array element atindex.static final GroupLayoutlayout()The layout of this structstatic longmember_count(MemorySegment struct) Getter for field:size_t member_countstatic voidmember_count(MemorySegment struct, long fieldValue) Setter for field:size_t member_countstatic final ValueLayout.OfLongLayout for field:size_t member_countstatic final longOffset for field:size_t member_countstatic MemorySegmentmembers(MemorySegment struct) Getter for field:const mln_json_member *membersstatic voidmembers(MemorySegment struct, MemorySegment fieldValue) Setter for field:const mln_json_member *membersstatic final AddressLayoutLayout for field:const mln_json_member *membersstatic final longOffset for field:const mln_json_member *membersstatic MemorySegmentreinterpret(MemorySegment addr, long elementCount, Arena arena, Consumer<MemorySegment> cleanup) Reinterpretsaddrusing targetarenaandcleanupAction(if any).static MemorySegmentreinterpret(MemorySegment addr, Arena arena, Consumer<MemorySegment> cleanup) Reinterpretsaddrusing targetarenaandcleanupAction(if any).static longsizeof()The size (in bytes) of this struct
-
Method Details
-
layout
The layout of this struct -
members$layout
Layout for field:const mln_json_member *members -
members$offset
public static final long members$offset()Offset for field:const mln_json_member *members -
members
Getter for field:const mln_json_member *members -
members
Setter for field:const mln_json_member *members -
member_count$layout
Layout for field:size_t member_count -
member_count$offset
public static final long member_count$offset()Offset for field:size_t member_count -
member_count
Getter for field:size_t member_count -
member_count
Setter for field:size_t member_count -
asSlice
Obtains a slice ofarrayParamwhich selects the array element atindex. The returned segment has addressarrayParam.address() + index * layout().byteSize() -
sizeof
public static long sizeof()The size (in bytes) of this struct -
allocate
Allocate a segment of sizelayout().byteSize()usingallocator -
allocateArray
Allocate an array of sizeelementCountusingallocator. The returned segment has sizeelementCount * layout().byteSize(). -
reinterpret
public static MemorySegment reinterpret(MemorySegment addr, Arena arena, Consumer<MemorySegment> cleanup) Reinterpretsaddrusing targetarenaandcleanupAction(if any). The returned segment has sizelayout().byteSize() -
reinterpret
public static MemorySegment reinterpret(MemorySegment addr, long elementCount, Arena arena, Consumer<MemorySegment> cleanup) Reinterpretsaddrusing targetarenaandcleanupAction(if any). The returned segment has sizeelementCount * layout().byteSize()
-