line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Aniki::Row::Joined; |
2
|
3
|
|
|
3
|
|
1363
|
use 5.014002; |
|
3
|
|
|
|
|
12
|
|
3
|
|
|
|
|
|
|
|
4
|
3
|
|
|
3
|
|
16
|
use strict; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
74
|
|
5
|
3
|
|
|
3
|
|
13
|
use warnings; |
|
3
|
|
|
|
|
5
|
|
|
3
|
|
|
|
|
76
|
|
6
|
|
|
|
|
|
|
|
7
|
3
|
|
|
3
|
|
14
|
use Carp qw/croak/; |
|
3
|
|
|
|
|
5
|
|
|
3
|
|
|
|
|
825
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub new { |
10
|
16
|
|
|
16
|
0
|
47
|
my ($class, @rows) = @_; |
11
|
16
|
|
|
|
|
31
|
my %rows = map { $_->table_name => $_ } @rows; |
|
32
|
|
|
|
|
103
|
|
12
|
16
|
|
|
|
|
66
|
return bless \%rows => $class; |
13
|
|
|
|
|
|
|
} |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
sub can { |
16
|
3
|
|
|
3
|
0
|
120
|
my ($invocant, $method) = @_; |
17
|
3
|
|
|
|
|
19
|
my $code = $invocant->SUPER::can($method); |
18
|
3
|
50
|
|
|
|
9
|
return $code if defined $code; |
19
|
|
|
|
|
|
|
|
20
|
3
|
50
|
|
|
|
9
|
if (ref $invocant) { |
21
|
3
|
|
|
|
|
7
|
my $self = $invocant; |
22
|
3
|
|
|
|
|
5
|
my $table_name = $method; |
23
|
3
|
100
|
|
0
|
|
14
|
return sub { shift->{$table_name} } if exists $self->{$table_name}; |
|
0
|
|
|
|
|
0
|
|
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
1
|
|
|
|
|
23
|
return undef; ## no critic |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
our $AUTOLOAD; |
30
|
|
|
|
|
|
|
sub AUTOLOAD { |
31
|
63
|
|
|
63
|
|
14130
|
my $invocant = shift; |
32
|
63
|
|
|
|
|
276
|
my $table_name = $AUTOLOAD =~ s/^.+://r; |
33
|
|
|
|
|
|
|
|
34
|
63
|
50
|
|
|
|
177
|
if (ref $invocant) { |
35
|
63
|
|
|
|
|
97
|
my $self = $invocant; |
36
|
63
|
100
|
|
|
|
258
|
return $self->{$table_name} if exists $self->{$table_name}; |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
1
|
|
33
|
|
|
26
|
my $msg = sprintf q{Can't locate object method "%s" via package "%s"}, $table_name, ref $invocant || $invocant; |
40
|
1
|
|
|
|
|
127
|
croak $msg; |
41
|
|
|
|
|
|
|
} |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
0
|
|
|
sub DESTROY {} # no autoload |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
1; |
46
|
|
|
|
|
|
|
__END__ |