- \ref GRAS_tut_tour_timers_intro
- \ref GRAS_tut_tour_timers_use
- \ref GRAS_tut_tour_timers_recap
-
+
<hr>
\section GRAS_tut_tour_timers_intro Introduction
One solution is to have the members re-register periodically, so that the
coordinator can detect the processes which didn't do so since a while, and
-dismiss them.
+dismiss them.
To implement this in GRAS, we need some more functions: gras_timer_repeat()
allows to specify a periodic action and gras_timer_delay() allows to get an
onto the server (to send messages) and a boolean indicating whether we are
done or not, just like we did on the server side in \ref
GRAS_tut_tour_globals. Here is the resulting global structure:
-\don'tinclude 07-timers.c
+\dontinclude 07-timers.c
\skip client_data
\until client_data_t
periodicity at which it was desinstalled (so that the same action can be
scheduled at different intervals, and each of them be desinstallable
separately).
-\don'tinclude 07-timers.c
+\dontinclude 07-timers.c
\skip gras_timer_cancel_repeat
\until gras_timer_cancel_repeat
be self-explanatory at this point. It could be cancelled before its
expiration using gras_timer_cancel_delay(), which accepts exactly the same
kind of arguments than gras_timer_cancel_repeat().
-\don'tinclude 07-timers.c
+\dontinclude 07-timers.c
\skip client_do_stop
\until end_of_client_do_stop