summaryrefslogtreecommitdiff
path: root/ev.pod
diff options
context:
space:
mode:
authorroot <root>2009-07-15 16:58:53 +0000
committerroot <root>2009-07-15 16:58:53 +0000
commit5c8cc800f487e020d33cd08727c442b6a8067d9d (patch)
tree96448386bbc5985c4bdd4e685abf06f27a89d401 /ev.pod
parent2978dc2e820ccb62fe7f3b35a0672455e592017e (diff)
*** empty log message ***
Diffstat (limited to 'ev.pod')
-rw-r--r--ev.pod12
1 files changed, 12 insertions, 0 deletions
diff --git a/ev.pod b/ev.pod
index feabbcc..289362b 100644
--- a/ev.pod
+++ b/ev.pod
@@ -1822,6 +1822,18 @@ C<repeat> value), or reset the running timer to the C<repeat> value.
This sounds a bit complicated, see L<Be smart about timeouts>, above, for a
usage example.
+=item ev_timer_remaining (loop, ev_timer *)
+
+Returns the remaining time until a timer fires. If the timer is active,
+then this time is relative to the current event loop time, otherwise it's
+the timeout value currently configured.
+
+That is, after an C<ev_timer_set (w, 5, 7)>, C<ev_timer_remaining> returns
+C<5>. When the timer is started and one second passes, C<ev_timer_remain>
+will return C<4>. When the timer expires and is restarted, it will return
+roughly C<7> (likely slightly less as callback invocation takes some time,
+too), and so on.
+
=item ev_tstamp repeat [read-write]
The current C<repeat> value. Will be used each time the watcher times out