org.purejava.appindicator._GPermissionClass 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 _GPermissionClass {
* struct _GObjectClass parent_class;
* int (*acquire)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* void (*acquire_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* int (*acquire_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* int (*release)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* void (*release_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* int (*release_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* void* reserved[16];
* };
* }
*/
public class _GPermissionClass {
public static MemoryLayout $LAYOUT() {
return constants$1204.const$5;
}
public static MemorySegment parent_class$slice(MemorySegment seg) {
return seg.asSlice(0, 136);
}
/**
* {@snippet :
* int (*acquire)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* }
*/
public interface acquire {
int apply(java.lang.foreign.MemorySegment a, java.lang.foreign.MemorySegment b, java.lang.foreign.MemorySegment user_data);
static MemorySegment allocate(acquire fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1205.const$0, fi, constants$12.const$2, scope);
}
static acquire ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _a, java.lang.foreign.MemorySegment _b, java.lang.foreign.MemorySegment _user_data) -> {
try {
return (int)constants$12.const$4.invokeExact(symbol, _a, _b, _user_data);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle acquire$VH() {
return constants$1205.const$1;
}
/**
* Getter for field:
* {@snippet :
* int (*acquire)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* }
*/
public static MemorySegment acquire$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1205.const$1.get(seg);
}
/**
* Setter for field:
* {@snippet :
* int (*acquire)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* }
*/
public static void acquire$set(MemorySegment seg, MemorySegment x) {
constants$1205.const$1.set(seg, x);
}
public static MemorySegment acquire$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1205.const$1.get(seg.asSlice(index*sizeof()));
}
public static void acquire$set(MemorySegment seg, long index, MemorySegment x) {
constants$1205.const$1.set(seg.asSlice(index*sizeof()), x);
}
public static acquire acquire(MemorySegment segment, Arena scope) {
return acquire.ofAddress(acquire$get(segment), scope);
}
/**
* {@snippet :
* void (*acquire_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* }
*/
public interface acquire_async {
void apply(java.lang.foreign.MemorySegment model, java.lang.foreign.MemorySegment path, java.lang.foreign.MemorySegment iter, java.lang.foreign.MemorySegment data);
static MemorySegment allocate(acquire_async fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1205.const$2, fi, constants$42.const$1, scope);
}
static acquire_async ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _model, java.lang.foreign.MemorySegment _path, java.lang.foreign.MemorySegment _iter, java.lang.foreign.MemorySegment _data) -> {
try {
constants$259.const$4.invokeExact(symbol, _model, _path, _iter, _data);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle acquire_async$VH() {
return constants$1205.const$3;
}
/**
* Getter for field:
* {@snippet :
* void (*acquire_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* }
*/
public static MemorySegment acquire_async$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1205.const$3.get(seg);
}
/**
* Setter for field:
* {@snippet :
* void (*acquire_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* }
*/
public static void acquire_async$set(MemorySegment seg, MemorySegment x) {
constants$1205.const$3.set(seg, x);
}
public static MemorySegment acquire_async$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1205.const$3.get(seg.asSlice(index*sizeof()));
}
public static void acquire_async$set(MemorySegment seg, long index, MemorySegment x) {
constants$1205.const$3.set(seg.asSlice(index*sizeof()), x);
}
public static acquire_async acquire_async(MemorySegment segment, Arena scope) {
return acquire_async.ofAddress(acquire_async$get(segment), scope);
}
/**
* {@snippet :
* int (*acquire_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* }
*/
public interface acquire_finish {
int apply(java.lang.foreign.MemorySegment a, java.lang.foreign.MemorySegment b, java.lang.foreign.MemorySegment user_data);
static MemorySegment allocate(acquire_finish fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1205.const$4, fi, constants$12.const$2, scope);
}
static acquire_finish ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _a, java.lang.foreign.MemorySegment _b, java.lang.foreign.MemorySegment _user_data) -> {
try {
return (int)constants$12.const$4.invokeExact(symbol, _a, _b, _user_data);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle acquire_finish$VH() {
return constants$1205.const$5;
}
/**
* Getter for field:
* {@snippet :
* int (*acquire_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* }
*/
public static MemorySegment acquire_finish$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1205.const$5.get(seg);
}
/**
* Setter for field:
* {@snippet :
* int (*acquire_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* }
*/
public static void acquire_finish$set(MemorySegment seg, MemorySegment x) {
constants$1205.const$5.set(seg, x);
}
public static MemorySegment acquire_finish$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1205.const$5.get(seg.asSlice(index*sizeof()));
}
public static void acquire_finish$set(MemorySegment seg, long index, MemorySegment x) {
constants$1205.const$5.set(seg.asSlice(index*sizeof()), x);
}
public static acquire_finish acquire_finish(MemorySegment segment, Arena scope) {
return acquire_finish.ofAddress(acquire_finish$get(segment), scope);
}
/**
* {@snippet :
* int (*release)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* }
*/
public interface release {
int apply(java.lang.foreign.MemorySegment a, java.lang.foreign.MemorySegment b, java.lang.foreign.MemorySegment user_data);
static MemorySegment allocate(release fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1206.const$0, fi, constants$12.const$2, scope);
}
static release ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _a, java.lang.foreign.MemorySegment _b, java.lang.foreign.MemorySegment _user_data) -> {
try {
return (int)constants$12.const$4.invokeExact(symbol, _a, _b, _user_data);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle release$VH() {
return constants$1206.const$1;
}
/**
* Getter for field:
* {@snippet :
* int (*release)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* }
*/
public static MemorySegment release$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1206.const$1.get(seg);
}
/**
* Setter for field:
* {@snippet :
* int (*release)(struct _GPermission*,struct _GCancellable*,struct _GError**);
* }
*/
public static void release$set(MemorySegment seg, MemorySegment x) {
constants$1206.const$1.set(seg, x);
}
public static MemorySegment release$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1206.const$1.get(seg.asSlice(index*sizeof()));
}
public static void release$set(MemorySegment seg, long index, MemorySegment x) {
constants$1206.const$1.set(seg.asSlice(index*sizeof()), x);
}
public static release release(MemorySegment segment, Arena scope) {
return release.ofAddress(release$get(segment), scope);
}
/**
* {@snippet :
* void (*release_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* }
*/
public interface release_async {
void apply(java.lang.foreign.MemorySegment model, java.lang.foreign.MemorySegment path, java.lang.foreign.MemorySegment iter, java.lang.foreign.MemorySegment data);
static MemorySegment allocate(release_async fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1206.const$2, fi, constants$42.const$1, scope);
}
static release_async ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _model, java.lang.foreign.MemorySegment _path, java.lang.foreign.MemorySegment _iter, java.lang.foreign.MemorySegment _data) -> {
try {
constants$259.const$4.invokeExact(symbol, _model, _path, _iter, _data);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle release_async$VH() {
return constants$1206.const$3;
}
/**
* Getter for field:
* {@snippet :
* void (*release_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* }
*/
public static MemorySegment release_async$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1206.const$3.get(seg);
}
/**
* Setter for field:
* {@snippet :
* void (*release_async)(struct _GPermission*,struct _GCancellable*,void (*)(struct _GObject*,struct _GAsyncResult*,void*),void*);
* }
*/
public static void release_async$set(MemorySegment seg, MemorySegment x) {
constants$1206.const$3.set(seg, x);
}
public static MemorySegment release_async$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1206.const$3.get(seg.asSlice(index*sizeof()));
}
public static void release_async$set(MemorySegment seg, long index, MemorySegment x) {
constants$1206.const$3.set(seg.asSlice(index*sizeof()), x);
}
public static release_async release_async(MemorySegment segment, Arena scope) {
return release_async.ofAddress(release_async$get(segment), scope);
}
/**
* {@snippet :
* int (*release_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* }
*/
public interface release_finish {
int apply(java.lang.foreign.MemorySegment a, java.lang.foreign.MemorySegment b, java.lang.foreign.MemorySegment user_data);
static MemorySegment allocate(release_finish fi, Arena scope) {
return RuntimeHelper.upcallStub(constants$1206.const$4, fi, constants$12.const$2, scope);
}
static release_finish ofAddress(MemorySegment addr, Arena arena) {
MemorySegment symbol = addr.reinterpret(arena, null);
return (java.lang.foreign.MemorySegment _a, java.lang.foreign.MemorySegment _b, java.lang.foreign.MemorySegment _user_data) -> {
try {
return (int)constants$12.const$4.invokeExact(symbol, _a, _b, _user_data);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
};
}
}
public static VarHandle release_finish$VH() {
return constants$1206.const$5;
}
/**
* Getter for field:
* {@snippet :
* int (*release_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* }
*/
public static MemorySegment release_finish$get(MemorySegment seg) {
return (java.lang.foreign.MemorySegment)constants$1206.const$5.get(seg);
}
/**
* Setter for field:
* {@snippet :
* int (*release_finish)(struct _GPermission*,struct _GAsyncResult*,struct _GError**);
* }
*/
public static void release_finish$set(MemorySegment seg, MemorySegment x) {
constants$1206.const$5.set(seg, x);
}
public static MemorySegment release_finish$get(MemorySegment seg, long index) {
return (java.lang.foreign.MemorySegment)constants$1206.const$5.get(seg.asSlice(index*sizeof()));
}
public static void release_finish$set(MemorySegment seg, long index, MemorySegment x) {
constants$1206.const$5.set(seg.asSlice(index*sizeof()), x);
}
public static release_finish release_finish(MemorySegment segment, Arena scope) {
return release_finish.ofAddress(release_finish$get(segment), scope);
}
public static MemorySegment reserved$slice(MemorySegment seg) {
return seg.asSlice(184, 128);
}
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); }
}