line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Tie::Simple::Util; |
2
|
|
|
|
|
|
|
$Tie::Simple::Util::VERSION = '1.04'; |
3
|
4
|
|
|
4
|
|
20
|
use strict; |
|
4
|
|
|
|
|
8
|
|
|
4
|
|
|
|
|
98
|
|
4
|
4
|
|
|
4
|
|
20
|
use warnings; |
|
4
|
|
|
|
|
7
|
|
|
4
|
|
|
|
|
301
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
# Copyright 2004, 2015 Andrew Sterling Hanenkamp. This software |
7
|
|
|
|
|
|
|
# is made available under the same terms as Perl itself. |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub _doit { |
10
|
52
|
|
|
52
|
|
71
|
my $self = shift; |
11
|
52
|
|
|
|
|
73
|
my $parent = shift; |
12
|
52
|
|
|
|
|
68
|
my $method = shift; |
13
|
|
|
|
|
|
|
|
14
|
52
|
100
|
|
|
|
297
|
if (defined $$self{subs}{$method}) { |
|
|
100
|
|
|
|
|
|
15
|
49
|
|
|
|
|
159
|
$$self{subs}{$method}->($$self{data}, @_); |
16
|
|
|
|
|
|
|
} elsif ($parent->can($method)) { |
17
|
4
|
|
|
4
|
|
18
|
no strict 'refs'; |
|
4
|
|
|
|
|
7
|
|
|
4
|
|
|
|
|
353
|
|
18
|
1
|
|
|
|
|
3
|
my $sub = "$parent\::$method"; |
19
|
1
|
|
|
|
|
2
|
&{$sub}($self, @_); |
|
1
|
|
|
|
|
6
|
|
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
1 |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
__END__ |