org.purejava.appindicator._GdkPixbufLoaderClass Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of libappindicator-gtk3-java-full Show documentation
Show all versions of libappindicator-gtk3-java-full Show documentation
Java bindings for libappindicator-gtk3 in 100% pure Java
// Generated by jextract
package org.purejava.appindicator;
import java.lang.foreign.Arena;
import java.lang.foreign.MemoryLayout;
import java.lang.foreign.MemorySegment;
import java.lang.foreign.SegmentAllocator;
import java.lang.invoke.VarHandle;
/**
* {@snippet :
* struct _GdkPixbufLoaderClass {
* struct _GObjectClass parent_class;
* void (*size_prepared)(struct _GdkPixbufLoader*,int,int);
* void (*area_prepared)(struct _GdkPixbufLoader*);
* void (*area_updated)(struct _GdkPixbufLoader*,int,int,int,int);
* void (*closed)(struct _GdkPixbufLoader*);
* };
* }
*/
public class _GdkPixbufLoaderClass {
public static MemoryLayout $LAYOUT() {
return constants$1901.const$0;
}
public static MemorySegment parent_class$slice(MemorySegment seg) {
return seg.asSlice(0, 136);
}
/**
* {@snippet :
* void (*size_prepared)(struct _GdkPixbufLoader*,int,int);
* }
*/
public interface size_prepared {
void apply(java.lang.foreign.MemorySegment _x0, int _x1, int _x2);
static MemorySegment allocate(size_prepared fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1901.const$1, fi, constants$467.const$3, scope);
}
static size_prepared ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment __x0, int __x1, int __x2) -> {
try {
constants$1901.const$2.invokeExact(symbol, __x0, __x1, __x2);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle size_prepared$VH() {
return constants$1901.const$3;
}
/**
* Getter for field:
* {@snippet :
* void (*size_prepared)(struct _GdkPixbufLoader*,int,int);
* }
*/
public static MemorySegment size_prepared$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1901.const$3.get(seg);
}
/**
* Setter for field:
* {@snippet :
* void (*size_prepared)(struct _GdkPixbufLoader*,int,int);
* }
*/
public static void size_prepared$set(MemorySegment seg, MemorySegment x) {
constants$1901.const$3.set(seg, x);
}
public static MemorySegment size_prepared$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1901.const$3.get(seg.asSlice(index*sizeof()));
}
public static void size_prepared$set(MemorySegment seg, long index, MemorySegment x) {
constants$1901.const$3.set(seg.asSlice(index*sizeof()), x);
}
public static size_prepared size_prepared(MemorySegment segment, Arena scope) {
return size_prepared.ofAddress(size_prepared$get(segment), scope);
}
/**
* {@snippet :
* void (*area_prepared)(struct _GdkPixbufLoader*);
* }
*/
public interface area_prepared {
void apply(java.lang.foreign.MemorySegment display);
static MemorySegment allocate(area_prepared fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1901.const$4, fi, constants$13.const$1, scope);
}
static area_prepared ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _display) -> {
try {
constants$13.const$3.invokeExact(symbol, _display);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle area_prepared$VH() {
return constants$1901.const$5;
}
/**
* Getter for field:
* {@snippet :
* void (*area_prepared)(struct _GdkPixbufLoader*);
* }
*/
public static MemorySegment area_prepared$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1901.const$5.get(seg);
}
/**
* Setter for field:
* {@snippet :
* void (*area_prepared)(struct _GdkPixbufLoader*);
* }
*/
public static void area_prepared$set(MemorySegment seg, MemorySegment x) {
constants$1901.const$5.set(seg, x);
}
public static MemorySegment area_prepared$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1901.const$5.get(seg.asSlice(index*sizeof()));
}
public static void area_prepared$set(MemorySegment seg, long index, MemorySegment x) {
constants$1901.const$5.set(seg.asSlice(index*sizeof()), x);
}
public static area_prepared area_prepared(MemorySegment segment, Arena scope) {
return area_prepared.ofAddress(area_prepared$get(segment), scope);
}
/**
* {@snippet :
* void (*area_updated)(struct _GdkPixbufLoader*,int,int,int,int);
* }
*/
public interface area_updated {
void apply(java.lang.foreign.MemorySegment _x0, int _x1, int _x2, int _x3, int _x4);
static MemorySegment allocate(area_updated fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1902.const$0, fi, constants$1643.const$1, scope);
}
static area_updated ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment __x0, int __x1, int __x2, int __x3, int __x4) -> {
try {
constants$1643.const$3.invokeExact(symbol, __x0, __x1, __x2, __x3, __x4);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle area_updated$VH() {
return constants$1902.const$1;
}
/**
* Getter for field:
* {@snippet :
* void (*area_updated)(struct _GdkPixbufLoader*,int,int,int,int);
* }
*/
public static MemorySegment area_updated$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1902.const$1.get(seg);
}
/**
* Setter for field:
* {@snippet :
* void (*area_updated)(struct _GdkPixbufLoader*,int,int,int,int);
* }
*/
public static void area_updated$set(MemorySegment seg, MemorySegment x) {
constants$1902.const$1.set(seg, x);
}
public static MemorySegment area_updated$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1902.const$1.get(seg.asSlice(index*sizeof()));
}
public static void area_updated$set(MemorySegment seg, long index, MemorySegment x) {
constants$1902.const$1.set(seg.asSlice(index*sizeof()), x);
}
public static area_updated area_updated(MemorySegment segment, Arena scope) {
return area_updated.ofAddress(area_updated$get(segment), scope);
}
/**
* {@snippet :
* void (*closed)(struct _GdkPixbufLoader*);
* }
*/
public interface closed {
void apply(java.lang.foreign.MemorySegment display);
static MemorySegment allocate(closed fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1902.const$2, fi, constants$13.const$1, scope);
}
static closed ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _display) -> {
try {
constants$13.const$3.invokeExact(symbol, _display);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle closed$VH() {
return constants$1902.const$3;
}
/**
* Getter for field:
* {@snippet :
* void (*closed)(struct _GdkPixbufLoader*);
* }
*/
public static MemorySegment closed$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1902.const$3.get(seg);
}
/**
* Setter for field:
* {@snippet :
* void (*closed)(struct _GdkPixbufLoader*);
* }
*/
public static void closed$set(MemorySegment seg, MemorySegment x) {
constants$1902.const$3.set(seg, x);
}
public static MemorySegment closed$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1902.const$3.get(seg.asSlice(index*sizeof()));
}
public static void closed$set(MemorySegment seg, long index, MemorySegment x) {
constants$1902.const$3.set(seg.asSlice(index*sizeof()), x);
}
public static closed closed(MemorySegment segment, Arena scope) {
return closed.ofAddress(closed$get(segment), scope);
}
public static long sizeof() { return $LAYOUT().byteSize(); }
public static MemorySegment allocate(SegmentAllocator allocator) { return allocator.allocate($LAYOUT()); }
public static MemorySegment allocateArray(long len, SegmentAllocator allocator) {
return allocator.allocate(MemoryLayout.sequenceLayout(len, $LAYOUT()));
}
public static MemorySegment ofAddress(MemorySegment addr, Arena scope) { return RuntimeHelper.asArray(addr, $LAYOUT(), 1, scope); }
}