line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
|
2
|
|
|
|
|
|
|
package DateTime::Format::Atom; |
3
|
|
|
|
|
|
|
|
4
|
3
|
|
|
3
|
|
380988
|
use strict; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
76
|
|
5
|
3
|
|
|
3
|
|
16
|
use warnings; |
|
3
|
|
|
|
|
4
|
|
|
3
|
|
|
|
|
80
|
|
6
|
|
|
|
|
|
|
|
7
|
3
|
|
|
3
|
|
2267
|
use version; our $VERSION = qv('v1.2.0'); |
|
3
|
|
|
|
|
6350
|
|
|
3
|
|
|
|
|
18
|
|
8
|
|
|
|
|
|
|
|
9
|
3
|
|
|
3
|
|
2594
|
use DateTime::Format::RFC3339 qw( ); |
|
3
|
|
|
|
|
159558
|
|
|
3
|
|
|
|
|
72
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
|
12
|
3
|
|
|
3
|
|
22
|
use constant FIRST_IDX => 0; |
|
3
|
|
|
|
|
5
|
|
|
3
|
|
|
|
|
188
|
|
13
|
3
|
|
|
3
|
|
16
|
use constant IDX_HELPER => FIRST_IDX + 0; |
|
3
|
|
|
|
|
5
|
|
|
3
|
|
|
|
|
142
|
|
14
|
3
|
|
|
3
|
|
15
|
use constant NEXT_IDX => FIRST_IDX + 1; |
|
3
|
|
|
|
|
5
|
|
|
3
|
|
|
|
|
546
|
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
sub new { |
18
|
1
|
|
|
1
|
0
|
2
|
my ($class, %opts) = @_; |
19
|
1
|
|
|
|
|
9
|
my $helper = DateTime::Format::RFC3339->new( uc_only => 1 ); |
20
|
1
|
|
|
|
|
12
|
return bless([ |
21
|
|
|
|
|
|
|
$helper, # IDX_HELPER |
22
|
|
|
|
|
|
|
], $class); |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub parse_datetime { |
27
|
1
|
|
|
1
|
1
|
964
|
my ($self, $str) = @_; |
28
|
|
|
|
|
|
|
|
29
|
1
|
50
|
|
|
|
8
|
$self = $self->new() |
30
|
|
|
|
|
|
|
if !ref($self); |
31
|
|
|
|
|
|
|
|
32
|
1
|
|
|
|
|
10
|
return $self->[IDX_HELPER]->parse_datetime($str); |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
sub format_datetime { |
37
|
1
|
|
|
1
|
1
|
706
|
my ($self, $dt) = @_; |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
# $self = $self->new() |
40
|
|
|
|
|
|
|
# if !ref($self); |
41
|
|
|
|
|
|
|
# |
42
|
|
|
|
|
|
|
# return $self->[IDX_HELPER]->format_datetime($dt); |
43
|
1
|
|
|
|
|
9
|
return DateTime::Format::RFC3339->format_datetime($dt); |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
1; |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
__END__ |