implement property (base) logic

Signed-off-by: Folling <mail@folling.io>
This commit is contained in:
Folling 2023-11-27 13:37:42 +01:00 committed by Folling
parent cc73cf000d
commit b37ca963cd
No known key found for this signature in database
3 changed files with 122 additions and 11 deletions

View file

@ -82,24 +82,24 @@ IKA_API struct IkarusPropertySource const * ikarus_property_get_source(IkarusPro
/// \param property The property to visit.
/// \pre \li Must not be null.
/// \pre \li Must exist.
/// \param toggle_property The function to call if the property is a toggle property. Skipped if null.
/// \param number_property The function to call if the property is a number property. Skipped if null.
/// \param text_property The function to call if the property is a text property. Skipped if null.
/// \param toggle_property_visitor The function to call if the property is a toggle property. Skipped if null.
/// \param number_property_visitor The function to call if the property is a number property. Skipped if null.
/// \param text_property_visitor The function to call if the property is a text property. Skipped if null.
/// \param data The data to pass to the functions.
IKA_API void ikarus_property_visit(
IkarusProperty * property,
void (*toggle_property)(struct IkarusToggleProperty *, void *),
void (*number_property)(struct IkarusNumberProperty *, void *),
void (*text_property)(struct IkarusTextProperty *, void *),
void (*toggle_property_visitor)(struct IkarusToggleProperty *, void *),
void (*number_property_visitor)(struct IkarusNumberProperty *, void *),
void (*text_property_visitor)(struct IkarusTextProperty *, void *),
void * data
);
/// \see ikarus_property_visit
IKA_API void ikarus_property_visit_const(
IkarusProperty const * property,
void (*toggle_property)(struct IkarusToggleProperty const *, void *),
void (*number_property)(struct IkarusNumberProperty const *, void *),
void (*text_property)(struct IkarusTextProperty const *, void *),
void (*toggle_property_visitor)(struct IkarusToggleProperty const *, void *),
void (*number_property_visitor)(struct IkarusNumberProperty const *, void *),
void (*text_property_visitor)(struct IkarusTextProperty const *, void *),
void * data
);