| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
package JSON::Hyper::Link; |
|
2
|
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:TOBYINK'; |
|
4
|
|
|
|
|
|
|
our $VERSION = '0.011'; |
|
5
|
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
10
|
use strict qw( subs vars ); |
|
|
1
|
|
|
|
|
2
|
|
|
|
1
|
|
|
|
|
167
|
|
|
7
|
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
sub new |
|
9
|
|
|
|
|
|
|
{ |
|
10
|
8
|
|
|
8
|
1
|
34
|
my ($class, $self) = @_; |
|
11
|
8
|
50
|
|
|
|
29
|
$self = +{ href => $self } unless ref $self; |
|
12
|
8
|
|
|
|
|
54
|
bless $self => $class; |
|
13
|
|
|
|
|
|
|
} |
|
14
|
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
my @attr = qw/ |
|
16
|
|
|
|
|
|
|
href |
|
17
|
|
|
|
|
|
|
rel |
|
18
|
|
|
|
|
|
|
targetSchema |
|
19
|
|
|
|
|
|
|
method |
|
20
|
|
|
|
|
|
|
enctype |
|
21
|
|
|
|
|
|
|
schema |
|
22
|
|
|
|
|
|
|
properties |
|
23
|
|
|
|
|
|
|
/; |
|
24
|
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
foreach my $attr (@attr) |
|
26
|
|
|
|
|
|
|
{ |
|
27
|
|
|
|
|
|
|
*$attr = sub { |
|
28
|
0
|
|
|
0
|
|
|
shift->{$attr}; |
|
29
|
|
|
|
|
|
|
}; |
|
30
|
|
|
|
|
|
|
} |
|
31
|
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
*target_schema = \&targetSchema; |
|
33
|
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
1; |
|
35
|
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
__END__ |