Query: coro::timer
OS: debian
Section: 3pm
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
Timer(3pm) User Contributed Perl Documentation Timer(3pm)NAMECoro::Timer - timers and timeouts, independent of any event loopSYNOPSIS# This package is mostly obsoleted by Coro::AnyEvent. use Coro::Timer qw(timeout); # nothing exported by defaultDESCRIPTIONThis package has been mostly obsoleted by Coro::AnyEvent, the only really useful function left in here is "timeout". $flag = timeout $seconds This function will wake up the current coroutine after $seconds seconds and sets $flag to true (it is false initially). If $flag goes out of scope earlier then nothing happens. This is used by Coro itself to implement the "timed_down", "timed_wait" etc. primitives. It is used like this: sub timed_wait { my $timeout = Coro::Timer::timeout 60; while (condition false) { Coro::schedule; # wait until woken up or timeout return 0 if $timeout; # timed out } return 1; # condition satisfied }AUTHORMarc Lehmann <schmorp@schmorp.de> http://home.schmorp.de/ perl v5.14.2 2012-04-13 Timer(3pm)
Related Man Pages |
---|
anyevent::impl::irssi(3pm) - debian |
coro::lwp(3pm) - debian |
coro::select(3pm) - debian |
coro::semaphore(3pm) - debian |
coro::signal(3pm) - debian |
Similar Topics in the Unix Linux Community |
---|
Adding the individual columns of a matrix. |
How can I do this in VI editor? |
Introduction |
New UNIX and Linux History Sections |
My first PERL incarnation... Audio Oscillograph |