messenger-gtk

Gtk+3 graphical user interfaces for GNUnet Messenger
Log | Files | Refs | Submodules | README | LICENSE

commit f5af3f2bc6c869562b3cfb1e416630412353f04f
parent 9e6401092b6ec30d9e914b252fa58f4f169b9419
Author: Jacki <jacki@thejackimonster.de>
Date:   Sun, 21 Jul 2024 03:30:34 +0200

Add documentation comments to schedule functions

Signed-off-by: Jacki <jacki@thejackimonster.de>

Diffstat:
Msrc/schedule.h | 32++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+), 0 deletions(-)

diff --git a/src/schedule.h b/src/schedule.h @@ -49,26 +49,58 @@ typedef struct MESSENGER_Schedule { guint poll; } MESSENGER_Schedule; +/** + * Initializes a schedule to synchronize a current thread + * with another certain thread via pipes and mutexes. + */ void schedule_init(MESSENGER_Schedule *schedule); +/** + * Completes initialization of a schedule to synchronize + * another thread with the GNUnet scheduler. + */ void schedule_load_gnunet(MESSENGER_Schedule *schedule); +/** + * Completes initialization of a schedule to synchronize + * another thread with the GLib/GTK scheduler. + */ void schedule_load_glib(MESSENGER_Schedule *schedule); +/** + * Cleanup a schedule and all of its resources for + * its synchronization. + */ void schedule_cleanup(MESSENGER_Schedule *schedule); +/** + * Calls a given function from the thread of a given + * schedule and waits for its completion until then + * in the current thread. + */ void schedule_sync_run(MESSENGER_Schedule *schedule, GSourceFunc function, gpointer data); +/** + * Locks the thread of a given schedule to wait + * until the schedule gets unlocked again from + * the current thread. Execution only continues + * in the current thread afterwards. + */ void schedule_sync_lock(MESSENGER_Schedule *schedule); +/** + * Unlocks the thread of a given schedule from + * the current thread. Execution continues in + * parallel again afterwards. + */ void schedule_sync_unlock(MESSENGER_Schedule *schedule);