ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/Coro/Coro/Timer.pm
(Generate patch)

Comparing Coro/Coro/Timer.pm (file contents):
Revision 1.7 by root, Sat Feb 9 18:53:03 2002 UTC vs.
Revision 1.8 by root, Mon Feb 25 03:21:09 2002 UTC

2 2
3Coro::Timer - simple timer package, independent of used event loops 3Coro::Timer - simple timer package, independent of used event loops
4 4
5=head1 SYNOPSIS 5=head1 SYNOPSIS
6 6
7 use Coro::Timer; 7 use Coro::Timer qw(sleep timeout);
8 # nothing exported by default
9
10 sleep 10;
8 11
9=head1 DESCRIPTION 12=head1 DESCRIPTION
10 13
11This package implements a simple timer callback system which works 14This package implements a simple timer callback system which works
12independent of the event loop mechanism used. If no event mechanism is 15independent of the event loop mechanism used. If no event mechanism is
30 33
31BEGIN { 34BEGIN {
32 eval "use Time::HiRes 'time'"; 35 eval "use Time::HiRes 'time'";
33} 36}
34 37
35$VERSION = 0.532; 38$VERSION = 0.533;
36@EXPORT_OK = qw(timeout sleep); 39@EXPORT_OK = qw(timeout sleep);
37 40
38=item $flag = timeout $seconds; 41=item $flag = timeout $seconds;
39 42
40This function will wake up the current coroutine after $seconds 43This function will wake up the current coroutine after $seconds

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines