Re: XForms: Timer descending

Jeff Pierce (piercej@preferred.com)
Tue, 23 Sep 1997 10:01:18 -0400

To subscribers of the xforms list from Jeff Pierce <piercej@preferred.com> :

Daniel Blvmer wrote:
>
> To subscribers of the xforms list from Daniel Blvmer <bloemer@cs.uni-bonn.de> :
>
> Hi,
>
> I try to use some kind of stopwatch for showing, how long my program is
> running.
> The timer object is capable in counting up the time, but it is still a
> timer.
> Is there a possiblity to set it to infinity, or something like that?
>
> --
> live long and prosper
>
> Daniel Bloemer
>

A timer is meant to be like an alarm clock. Set it and have a callback
for when it times out. Therefore you can then check for other events to
have happened. I used one to go off every second to query a piece of
equipment that could not initiate communications. Plus, I reset the
timer every time in the callback.

I would think you want to use the system calls to get task runtime if
you are really interested in task time accuracy.

Or, if accuracy is not a priority, set a timer and have it's callback
increment a counter and then reset the timer. Remember, even the Xforms
doc states that the timer is NOT intended for acurate timing.

Jeff Pierce
piercej@preferred.com
_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuf2.usuhs.mil or see
http://bob.usuf2.usuhs.mil/mailserv/xforms.html
Xforms Home Page: http://bragg.phys.uwm.edu/xforms
List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/