Class mln_feature

java.lang.Object
org.maplibre.nativeffi.internal.c.mln_feature

public class mln_feature extends Object
struct mln_feature {
    uint32_t size;
    const mln_geometry *geometry;
    const mln_json_member *properties;
    size_t property_count;
    uint32_t identifier_type;
    union {
        uint64_t uint_value;
        int64_t int_value;
        double double_value;
        mln_string_view string_value;
    } identifier;
}
  • Method Details

    • layout

      public static final GroupLayout layout()
      The layout of this struct
    • size$layout

      public static final ValueLayout.OfInt size$layout()
      Layout for field:
      uint32_t size
      
    • size$offset

      public static final long size$offset()
      Offset for field:
      uint32_t size
      
    • size

      public static int size(MemorySegment struct)
      Getter for field:
      uint32_t size
      
    • size

      public static void size(MemorySegment struct, int fieldValue)
      Setter for field:
      uint32_t size
      
    • geometry$layout

      public static final AddressLayout geometry$layout()
      Layout for field:
      const mln_geometry *geometry
      
    • geometry$offset

      public static final long geometry$offset()
      Offset for field:
      const mln_geometry *geometry
      
    • geometry

      public static MemorySegment geometry(MemorySegment struct)
      Getter for field:
      const mln_geometry *geometry
      
    • geometry

      public static void geometry(MemorySegment struct, MemorySegment fieldValue)
      Setter for field:
      const mln_geometry *geometry
      
    • properties$layout

      public static final AddressLayout properties$layout()
      Layout for field:
      const mln_json_member *properties
      
    • properties$offset

      public static final long properties$offset()
      Offset for field:
      const mln_json_member *properties
      
    • properties

      public static MemorySegment properties(MemorySegment struct)
      Getter for field:
      const mln_json_member *properties
      
    • properties

      public static void properties(MemorySegment struct, MemorySegment fieldValue)
      Setter for field:
      const mln_json_member *properties
      
    • property_count$layout

      public static final ValueLayout.OfLong property_count$layout()
      Layout for field:
      size_t property_count
      
    • property_count$offset

      public static final long property_count$offset()
      Offset for field:
      size_t property_count
      
    • property_count

      public static long property_count(MemorySegment struct)
      Getter for field:
      size_t property_count
      
    • property_count

      public static void property_count(MemorySegment struct, long fieldValue)
      Setter for field:
      size_t property_count
      
    • identifier_type$layout

      public static final ValueLayout.OfInt identifier_type$layout()
      Layout for field:
      uint32_t identifier_type
      
    • identifier_type$offset

      public static final long identifier_type$offset()
      Offset for field:
      uint32_t identifier_type
      
    • identifier_type

      public static int identifier_type(MemorySegment struct)
      Getter for field:
      uint32_t identifier_type
      
    • identifier_type

      public static void identifier_type(MemorySegment struct, int fieldValue)
      Setter for field:
      uint32_t identifier_type
      
    • identifier$layout

      public static final GroupLayout identifier$layout()
      Layout for field:
      union {
          uint64_t uint_value;
          int64_t int_value;
          double double_value;
          mln_string_view string_value;
      } identifier
      
    • identifier$offset

      public static final long identifier$offset()
      Offset for field:
      union {
          uint64_t uint_value;
          int64_t int_value;
          double double_value;
          mln_string_view string_value;
      } identifier
      
    • identifier

      public static MemorySegment identifier(MemorySegment struct)
      Getter for field:
      union {
          uint64_t uint_value;
          int64_t int_value;
          double double_value;
          mln_string_view string_value;
      } identifier
      
    • identifier

      public static void identifier(MemorySegment struct, MemorySegment fieldValue)
      Setter for field:
      union {
          uint64_t uint_value;
          int64_t int_value;
          double double_value;
          mln_string_view string_value;
      } identifier
      
    • asSlice

      public static MemorySegment asSlice(MemorySegment array, long index)
      Obtains a slice of arrayParam which selects the array element at index. The returned segment has address arrayParam.address() + index * layout().byteSize()
    • sizeof

      public static long sizeof()
      The size (in bytes) of this struct
    • allocate

      public static MemorySegment allocate(SegmentAllocator allocator)
      Allocate a segment of size layout().byteSize() using allocator
    • allocateArray

      public static MemorySegment allocateArray(long elementCount, SegmentAllocator allocator)
      Allocate an array of size elementCount using allocator. The returned segment has size elementCount * layout().byteSize().
    • reinterpret

      public static MemorySegment reinterpret(MemorySegment addr, Arena arena, Consumer<MemorySegment> cleanup)
      Reinterprets addr using target arena and cleanupAction (if any). The returned segment has size layout().byteSize()
    • reinterpret

      public static MemorySegment reinterpret(MemorySegment addr, long elementCount, Arena arena, Consumer<MemorySegment> cleanup)
      Reinterprets addr using target arena and cleanupAction (if any). The returned segment has size elementCount * layout().byteSize()