Package org.freedesktop.wayland.raw
Class timeval
java.lang.Object
org.freedesktop.wayland.raw.timeval
-
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 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 structstatic longtv_sec(MemorySegment struct) Getter for field:__time_t tv_secstatic voidtv_sec(MemorySegment struct, long fieldValue) Setter for field:__time_t tv_secstatic final ValueLayout.OfLongLayout for field:__time_t tv_secstatic final longOffset for field:__time_t tv_secstatic longtv_usec(MemorySegment struct) Getter for field:__suseconds_t tv_usecstatic voidtv_usec(MemorySegment struct, long fieldValue) Setter for field:__suseconds_t tv_usecstatic final ValueLayout.OfLongLayout for field:__suseconds_t tv_usecstatic final longOffset for field:__suseconds_t tv_usec
-
Method Details
-
layout
The layout of this struct -
tv_sec$layout
Layout for field:__time_t tv_sec -
tv_sec$offset
public static final long tv_sec$offset()Offset for field:__time_t tv_sec -
tv_sec
Getter for field:__time_t tv_sec -
tv_sec
Setter for field:__time_t tv_sec -
tv_usec$layout
Layout for field:__suseconds_t tv_usec -
tv_usec$offset
public static final long tv_usec$offset()Offset for field:__suseconds_t tv_usec -
tv_usec
Getter for field:__suseconds_t tv_usec -
tv_usec
Setter for field:__suseconds_t tv_usec -
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()
-