File Coverage

blib/lib/Event/var.pm
Criterion Covered Total %
statement 14 14 100.0
branch n/a
condition 1 2 50.0
subroutine 4 4 100.0
pod 0 1 0.0
total 19 21 90.4


line stmt bran cond sub pod time code
1 24     24   162 use strict;
  24         1675  
  24         2451  
2             package Event::var;
3 24     24   1752 use base 'Event::Watcher';
  24         1603  
  24         3983  
4 24     24   3629 use vars qw(@ATTRIBUTE);
  24         46  
  24         2839  
5             @ATTRIBUTE = qw(var poll);
6              
7             'Event::Watcher'->register;
8              
9             sub new {
10             # lock %Event::;
11              
12 10     10 0 17 my $class = shift;
13 10         33 my %arg = @_;
14 10   50     266 my $o = allocate($class, delete $arg{attach_to} || {});
15 10         47 $o->init(\%arg);
16 7         28 $o;
17             }
18              
19             1;