[Developers] Suggestion: New API CCTK_Announce
Erik Schnetter
schnetter at aei.mpg.de
Fri Jun 3 08:21:50 CDT 2005
If different thorns want to announce certain events to the world, then
it would be useful to have an API for that. Currently, then can call
something like
CCTK_INFO ("[keyword] Some message")
and the planned infrastructure would propagate that event.
The drawback is that the text [keyword] does not look nice -- it is not
meant for humans -- and parsing that string is some effort. Without
keywords, it will be almost impossible to filter out the interesting
events from the background noise that happens during an evolution.
A new routine
CCTK_Announce ("keyword", "value")
would be more suitable for that. Thorns that registered themselves to
receive announced information then receive the name of the announcing
thorn, the keyword, and the value, which would in general either be
further information, such as in
CCTK_Announce ("cctk_iteration", "42")
Such an announcing API could distinguish between three types of
announced values, namely ints, reals, and strings.
The API can either be a flesh API, or can use aliased functions.
-erik
--
Erik Schnetter <schnetter at aei.mpg.de> http://www.aei.mpg.de/~eschnett/
My email is as private as my paper mail. I therefore support encrypting
and signing email messages. Get my PGP key from www.keyserver.net.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://www.cactuscode.org/pipermail/developers/attachments/20050603/3d226efa/attachment-0002.bin
More information about the Developers
mailing list