line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
24
|
|
|
24
|
|
155
|
use strict; |
|
24
|
|
|
|
|
51
|
|
|
24
|
|
|
|
|
881
|
|
2
|
|
|
|
|
|
|
package Event::io; |
3
|
24
|
|
|
24
|
|
120
|
use vars qw(@ISA @EXPORT_OK @ATTRIBUTE); |
|
24
|
|
|
|
|
46
|
|
|
24
|
|
|
|
|
3315
|
|
4
|
|
|
|
|
|
|
@ISA = qw(Event::Watcher Exporter); |
5
|
|
|
|
|
|
|
@EXPORT_OK = qw(R W E T); # bit constants |
6
|
|
|
|
|
|
|
@ATTRIBUTE = qw(poll fd timeout timeout_cb); |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
'Event::Watcher'->register; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
sub new { |
11
|
|
|
|
|
|
|
# lock %Event::; |
12
|
|
|
|
|
|
|
|
13
|
3809
|
|
|
3809
|
0
|
5573
|
my $class = shift; |
14
|
3809
|
|
|
|
|
12259
|
my %arg = @_; |
15
|
3809
|
|
50
|
|
|
25978
|
my $o = allocate($class, delete $arg{attach_to} || {}); |
16
|
3809
|
|
|
|
|
11689
|
$o->init(\%arg); |
17
|
3806
|
|
|
|
|
13565
|
$o; |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
1; |