Package org.gnome.gio
Interface SettingsGetMapping
- 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.
@FunctionalInterface
@Generated("io.github.jwharm.JavaGI")
public interface SettingsGetMapping
extends FunctionPointer
Functional interface declaration of the
SettingsGetMapping callback.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbooleanrun(@Nullable Variant value, @Nullable Out<MemorySegment> result) The type of the function that is used to convert from a value stored in aSettingsto a value that is useful to the application.default MemorySegmenttoCallback(Arena arena) Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment)method.default intupcall(MemorySegment value, MemorySegment result, MemorySegment userData) Theupcallmethod is called from native code.
-
Method Details
-
run
The type of the function that is used to convert from a value stored in aSettingsto a value that is useful to the application.If the value is successfully mapped, the result should be stored at
resultand true returned. If mapping fails (for example, ifvalueis not in the right format) then false should be returned.If
valueisNULLthen it means that the mapping function is being given a ‘last chance’ to successfully return a valid value. True must be returned in this case. -
upcall
Theupcallmethod is called from native code. The parameters are marshaled andrun(org.gnome.glib.Variant, org.javagi.base.Out<java.lang.foreign.MemorySegment>)is executed. -
toCallback
Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment)method.- Specified by:
toCallbackin interfaceFunctionPointer- Parameters:
arena- the arena in which the function pointer is allocated- Returns:
- the native function pointer
-