Package ch.bailu.gtk.glib
Class HookList
java.lang.Object
ch.bailu.gtk.type.Type
ch.bailu.gtk.type.Pointer
ch.bailu.gtk.type.Record
ch.bailu.gtk.glib.HookList
- All Implemented Interfaces:
PointerInterface
The #GHookList struct represents a list of hook functions.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
static interface
static interface
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
unusedstatic final String
the function to call to finalize a #GHook element.static final String
the size of the #GHookList elements, in bytesstatic final String
the first #GHook element in the liststatic final String
1 if the #GHookList has been initializedstatic final String
the next free #GHook id -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
Removes all the #GHook elements from a #GHookList.static ClassHandler
unusedch.bailu.gtk.glib.JnaHookList.OnHookFinalizeFunc
the function to call to finalize a #GHook element.the first #GHook element in the listint
the size of the #GHookList elements, in bytesint
1 if the #GHookList has been initializedlong
the next free #GHook idvoid
init
(int hook_size) Initializes a #GHookList.void
invoke
(boolean may_recurse) Calls all of the #GHook functions in a #GHookList.void
invokeCheck
(boolean may_recurse) Calls all of the #GHook functions in a #GHookList.void
marshal
(boolean may_recurse, HookList.OnHookMarshaller marshaller, Pointer marshal_data) Calls a function on each valid #GHook.void
marshalCheck
(boolean may_recurse, HookList.OnHookCheckMarshaller marshaller, Pointer marshal_data) Calls a function on each valid #GHook and destroys it if the
function returns %FALSE.void
setFieldDummy3
(Pointer dummy3) unusedvoid
setFieldFinalizeHook
(HookList.OnHookFinalizeFunc finalize_hook) the function to call to finalize a #GHook element.void
setFieldHooks
(Hook hooks) the first #GHook element in the listvoid
setFieldHookSize
(int hook_size) the size of the #GHookList elements, in bytesvoid
setFieldIsSetup
(int is_setup) 1 if the #GHookList has been initializedvoid
setFieldSeqId
(long seq_id) the next free #GHook idMethods inherited from class ch.bailu.gtk.type.Pointer
asCPointer, cast, connectSignal, disconnectSignals, disconnectSignals, equals, hashCode, throwIfNull, throwNullPointerException, toString, unregisterCallbacks, unregisterCallbacks
Methods inherited from class ch.bailu.gtk.type.Type
asCPointer, asCPointer, asCPointerNotNull, asJnaPointer, asJnaPointer, asPointer, asPointer, cast, cast, throwIfNull
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface ch.bailu.gtk.type.PointerInterface
asCPointerNotNull, asJnaPointer, asPointer, isNotNull, isNull
-
Field Details
-
SEQ_ID
the next free #GHook id- See Also:
-
HOOK_SIZE
the size of the #GHookList elements, in bytes- See Also:
-
IS_SETUP
1 if the #GHookList has been initialized- See Also:
-
HOOKS
the first #GHook element in the list- See Also:
-
DUMMY3
unused- See Also:
-
FINALIZE_HOOK
the function to call to finalize a #GHook element.
The default behaviour is to call the hooks @destroy function
SeeHookList.OnHookFinalizeFunc.onHookFinalizeFunc(ch.bailu.gtk.lib.handler.CallbackHandler, ch.bailu.gtk.glib.HookList, ch.bailu.gtk.glib.Hook)
- See Also:
-
-
Constructor Details
-
HookList
-
-
Method Details
-
getClassHandler
-
setFieldSeqId
public void setFieldSeqId(long seq_id) the next free #GHook id -
getFieldSeqId
public long getFieldSeqId()the next free #GHook id -
setFieldHookSize
public void setFieldHookSize(int hook_size) the size of the #GHookList elements, in bytes -
getFieldHookSize
public int getFieldHookSize()the size of the #GHookList elements, in bytes -
setFieldIsSetup
public void setFieldIsSetup(int is_setup) 1 if the #GHookList has been initialized -
getFieldIsSetup
public int getFieldIsSetup()1 if the #GHookList has been initialized -
setFieldHooks
the first #GHook element in the list -
getFieldHooks
the first #GHook element in the list -
setFieldDummy3
unused -
getFieldDummy3
unused -
setFieldFinalizeHook
the function to call to finalize a #GHook element.
The default behaviour is to call the hooks @destroy function
SeeHookList.OnHookFinalizeFunc.onHookFinalizeFunc(ch.bailu.gtk.lib.handler.CallbackHandler, ch.bailu.gtk.glib.HookList, ch.bailu.gtk.glib.Hook)
-
getFieldFinalizeHook
public ch.bailu.gtk.glib.JnaHookList.OnHookFinalizeFunc getFieldFinalizeHook()the function to call to finalize a #GHook element.
The default behaviour is to call the hooks @destroy function
SeeHookList.OnHookFinalizeFunc.onHookFinalizeFunc(ch.bailu.gtk.lib.handler.CallbackHandler, ch.bailu.gtk.glib.HookList, ch.bailu.gtk.glib.Hook)
-
clear
public void clear()Removes all the #GHook elements from a #GHookList. -
init
public void init(int hook_size) Initializes a #GHookList.
This must be called before the #GHookList is used.- Parameters:
hook_size
- the size of each element in the #GHookList, typically `sizeof (GHook)`.
-
invoke
public void invoke(boolean may_recurse) Calls all of the #GHook functions in a #GHookList.- Parameters:
may_recurse
- %TRUE if functions which are already running (e.g. in another thread) can be called. If set to %FALSE, these are skipped
-
invokeCheck
public void invokeCheck(boolean may_recurse) Calls all of the #GHook functions in a #GHookList.
Any function which returns %FALSE is removed from the #GHookList.- Parameters:
may_recurse
- %TRUE if functions which are already running (e.g. in another thread) can be called. If set to %FALSE, these are skipped
-
marshal
public void marshal(boolean may_recurse, HookList.OnHookMarshaller marshaller, @Nullable Pointer marshal_data) Calls a function on each valid #GHook.- Parameters:
may_recurse
- %TRUE if hooks which are currently running (e.g. in another thread) are considered valid. If set to %FALSE, these are skippedmarshaller
- the function to call for each #GHookmarshal_data
- data to pass to @marshaller
-
marshalCheck
public void marshalCheck(boolean may_recurse, HookList.OnHookCheckMarshaller marshaller, @Nullable Pointer marshal_data) Calls a function on each valid #GHook and destroys it if the
function returns %FALSE.- Parameters:
may_recurse
- %TRUE if hooks which are currently running (e.g. in another thread) are considered valid. If set to %FALSE, these are skippedmarshaller
- the function to call for each #GHookmarshal_data
- data to pass to @marshaller
-