Class EcsTimer

java.lang.Object
com.github.elebras1.flecs.EcsTimer

public class EcsTimer extends Object
struct EcsTimer {
    float timeout;
    float time;
    float overshoot;
    int32_t fired_count;
    _Bool active;
    _Bool single_shot;
}
  • Method Details

    • layout

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

      public static final ValueLayout.OfFloat timeout$layout()
      Layout for field:
      float timeout
      
    • timeout$offset

      public static final long timeout$offset()
      Offset for field:
      float timeout
      
    • timeout

      public static float timeout(MemorySegment struct)
      Getter for field:
      float timeout
      
    • timeout

      public static void timeout(MemorySegment struct, float fieldValue)
      Setter for field:
      float timeout
      
    • time$layout

      public static final ValueLayout.OfFloat time$layout()
      Layout for field:
      float time
      
    • time$offset

      public static final long time$offset()
      Offset for field:
      float time
      
    • time

      public static float time(MemorySegment struct)
      Getter for field:
      float time
      
    • time

      public static void time(MemorySegment struct, float fieldValue)
      Setter for field:
      float time
      
    • overshoot$layout

      public static final ValueLayout.OfFloat overshoot$layout()
      Layout for field:
      float overshoot
      
    • overshoot$offset

      public static final long overshoot$offset()
      Offset for field:
      float overshoot
      
    • overshoot

      public static float overshoot(MemorySegment struct)
      Getter for field:
      float overshoot
      
    • overshoot

      public static void overshoot(MemorySegment struct, float fieldValue)
      Setter for field:
      float overshoot
      
    • fired_count$layout

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

      public static final long fired_count$offset()
      Offset for field:
      int32_t fired_count
      
    • fired_count

      public static int fired_count(MemorySegment struct)
      Getter for field:
      int32_t fired_count
      
    • fired_count

      public static void fired_count(MemorySegment struct, int fieldValue)
      Setter for field:
      int32_t fired_count
      
    • active$layout

      public static final ValueLayout.OfBoolean active$layout()
      Layout for field:
      _Bool active
      
    • active$offset

      public static final long active$offset()
      Offset for field:
      _Bool active
      
    • active

      public static boolean active(MemorySegment struct)
      Getter for field:
      _Bool active
      
    • active

      public static void active(MemorySegment struct, boolean fieldValue)
      Setter for field:
      _Bool active
      
    • single_shot$layout

      public static final ValueLayout.OfBoolean single_shot$layout()
      Layout for field:
      _Bool single_shot
      
    • single_shot$offset

      public static final long single_shot$offset()
      Offset for field:
      _Bool single_shot
      
    • single_shot

      public static boolean single_shot(MemorySegment struct)
      Getter for field:
      _Bool single_shot
      
    • single_shot

      public static void single_shot(MemorySegment struct, boolean fieldValue)
      Setter for field:
      _Bool single_shot
      
    • 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()