Class MenuLinkIter
- All Implemented Interfaces:
Proxy
- Direct Known Subclasses:
MenuLinkIter.MenuLinkIter$Impl
GMenuLinkIter is an opaque structure type. You must access it using
the functions below.- Since:
- 2.32
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classMenuLinkIter.Builder<B extends MenuLinkIter.Builder<B>>Inner class implementing a builder pattern to construct a GObject with properties.static classThe MenuLinkIter$Impl type represents a native instance of the abstract MenuLinkIter class.static classNested classes/interfaces inherited from class org.gnome.gobject.GObject
GObject.NotifyCallback, GObject.ObjectClass -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new MenuLinkIter.MenuLinkIter(MemorySegment address) Create a MenuLinkIter proxy instance for the provided memory address. -
Method Summary
Modifier and TypeMethodDescriptionprotected MenuLinkIterasParent()Returns this instance as if it were its parent type.static MemoryLayoutThe memory layout of the native struct.getName()Gets the name of the link at the current iterator position.booleanThis function combines g_menu_link_iter_next() with g_menu_link_iter_get_name() and g_menu_link_iter_get_value().static @Nullable TypegetType()Get the GType of the MenuLinkIter classgetValue()Gets the linkedGMenuModelat the current iterator position.booleannext()Attempts to advance the iterator to the next (possibly first) link.Methods inherited from class org.gnome.gobject.GObject
addToggleRef, addWeakPointer, bindProperty, bindProperty, bindProperty, bindPropertyFull, bindPropertyFull, bindPropertyWithClosures, bindPropertyWithClosures, builder, compatControl, connect, connect, connect, constructed, disconnect, dispatchPropertiesChanged, dispose, dupData, dupQdata, emit, emitNotify, finalize_, forceFloating, freezeNotify, get, getData, getProperty, getProperty, getProperty, getQdata, getv, interfaceFindProperty, interfaceInstallProperty, interfaceListProperties, isFloating, newInstance, newInstance, newv, notify, notify, notifyByPspec, onNotify, ref, refSink, removeToggleRef, removeWeakPointer, replaceData, replaceQdata, runDispose, set, setData, setDataFull, setProperty, setProperty, setProperty, setQdata, setQdataFull, setv, stealData, stealQdata, takeRef, thawNotify, unref, watchClosure, weakRef, weakUnref, withPropertiesMethods inherited from class org.gnome.gobject.TypeInstance
callParent, callParent, cast, getPrivate, readGClass, writeGClassMethods inherited from class org.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
MenuLinkIter
Create a MenuLinkIter proxy instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
MenuLinkIter
public MenuLinkIter()Creates a new MenuLinkIter.
-
-
Method Details
-
getType
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
asParent
Returns this instance as if it were its parent type. This is mostly synonymous to the Javasuperkeyword, but will set the native typeclass function pointers to the parent type. When overriding a native virtual method in Java, "chaining up" withsuper.methodName()doesn't work, because it invokes the overridden function pointer again. To chain up, callasParent().methodName(). This will call the native function pointer of this virtual method in the typeclass of the parent type. -
getName
Gets the name of the link at the current iterator position.The iterator is not advanced.
- Returns:
- the type of the link
- Since:
- 2.32
-
getNext
This function combines g_menu_link_iter_next() with g_menu_link_iter_get_name() and g_menu_link_iter_get_value().First the iterator is advanced to the next (possibly first) link. If that fails, then
falseis returned and there are no other effects.If successful,
outLinkandvalueare set to the name andGMenuModelof the link that has just been advanced to. At this point, g_menu_link_iter_get_name() and g_menu_link_iter_get_value() will return the same values again.The value returned in
outLinkremains valid for as long as the iterator remains at the current position. The value returned invaluemust be unreffed using g_object_unref() when it is no longer in use.- Parameters:
outLink- the name of the linkvalue- the linkedGMenuModel- Returns:
trueon success, orfalseif there is no additional link- Since:
- 2.32
-
getValue
Gets the linkedGMenuModelat the current iterator position.The iterator is not advanced.
- Returns:
- the
GMenuModelthat is linked to - Since:
- 2.32
-
next
public boolean next()Attempts to advance the iterator to the next (possibly first) link.trueis returned on success, orfalseif there are no more links.You must call this function when you first acquire the iterator to advance it to the first link (and determine if the first link exists at all).
- Returns:
trueon success, orfalsewhen there are no more links- Since:
- 2.32
-