Package org.gnome.gio
Interface ListModel.ItemsChangedCallback
- All Superinterfaces:
FunctionPointer
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Functional interface declaration of the
ItemsChangedCallback callback.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidrun(int position, int removed, int added) This signal is emitted whenever items were added to or removed fromlist.Atposition,removeditems were removed andaddeditems were added in their place.default MemorySegmenttoCallback(Arena arena) Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, int, int, int)method.default voidupcall(MemorySegment sourceListModel, int position, int removed, int added) Theupcallmethod is called from native code.
-
Method Details
-
run
void run(int position, int removed, int added) This signal is emitted whenever items were added to or removed fromlist.Atposition,removeditems were removed andaddeditems were added in their place.Note: If
removed != added, the positions of all later items in the model change.- Since:
- 2.44
-
upcall
Theupcallmethod is called from native code. The parameters are marshaled andrun(int, int, int)is executed. -
toCallback
Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, int, int, int)method.- Specified by:
toCallbackin interfaceFunctionPointer- Parameters:
arena- the arena in which the function pointer is allocated- Returns:
- the native function pointer
-