line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package WWW::Blog::Metadata::OpenID; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
24994
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
45
|
|
4
|
1
|
|
|
1
|
|
5
|
use vars qw($VERSION); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
86
|
|
5
|
|
|
|
|
|
|
$VERSION = '0.01'; |
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
495
|
use WWW::Blog::Metadata; |
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
use URI; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
WWW::Blog::Metadata->mk_accessors(qw( openid_server openid_delegate )); |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
sub on_got_tag { |
13
|
|
|
|
|
|
|
my $class = shift; |
14
|
|
|
|
|
|
|
my($meta, $tag, $attr, $base_uri) = @_; |
15
|
|
|
|
|
|
|
if ($tag eq 'link' && $attr->{rel}) { |
16
|
|
|
|
|
|
|
my %rel = map { $_ => 1 } split /\s+/, lc $attr->{rel}; |
17
|
|
|
|
|
|
|
for my $role (qw( server delegate )) { |
18
|
|
|
|
|
|
|
if ($rel{"openid.$role"}) { |
19
|
|
|
|
|
|
|
my $meth = "openid_$role"; |
20
|
|
|
|
|
|
|
$meta->$meth(URI->new_abs($attr->{href}, $base_uri)->as_string); |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
} |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub on_got_tag_order { 99 } |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
1; |
29
|
|
|
|
|
|
|
__END__ |