line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package PX::API::Response::Rest; |
2
|
1
|
|
|
1
|
|
1972
|
use warnings; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
41
|
|
3
|
1
|
|
|
1
|
|
5
|
use strict; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
32
|
|
4
|
1
|
|
|
1
|
|
6
|
use Carp; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
74
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
5
|
use version; our $VERSION = qv('0.0.3'); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
6
|
|
7
|
|
|
|
|
|
|
|
8
|
1
|
|
|
1
|
|
470
|
use XML::Simple; |
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
sub new { |
11
|
|
|
|
|
|
|
my $class = shift; |
12
|
|
|
|
|
|
|
my $args = shift || {}; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
$class = ref($class) || $class; |
15
|
|
|
|
|
|
|
my $self = bless {}, $class; |
16
|
|
|
|
|
|
|
$self->{'xs'} = XML::Simple->new(KeepRoot => 1, KeyAttr => []); |
17
|
|
|
|
|
|
|
return $self; |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
sub parse { |
21
|
|
|
|
|
|
|
my $self = shift; |
22
|
|
|
|
|
|
|
my $xml = shift; |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
my $xs = $self->{'xs'}; |
25
|
|
|
|
|
|
|
my $ref = $xs->XMLin($xml); |
26
|
|
|
|
|
|
|
return $ref; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
sub format { 'rest' } |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
1; |
33
|
|
|
|
|
|
|
__END__ |