| 1 | package Net::HTTP::API::Parser::XML; | ||
| 2 | 1 | ▶ | BEGIN { |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 3 | 1 | $Net::HTTP::API::Parser::XML::VERSION = '0.14'; | |
| 4 | } | ||
| 5 | |||
| 6 | # ABSTRACT: Parse XML result | ||
| 7 | |||
| 8 | 1 | ▶ | use XML::Simple; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 9 | 1 | ▶ | use Moose; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 10 | 1 | extends 'Net::HTTP::API::Parser'; | |
| 11 | |||
| 12 | has _xml_parser => ( | ||
| 13 | is => 'rw', | ||
| 14 | isa => 'XML::Simple', | ||
| 15 | lazy => 1, | ||
| 16 | 0 | ▶ | default => sub { XML::SImple->new(ForceArray => 0) } |
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||
| 17 | 1 | ); | |
| 18 | |||
| 19 | 0 | ▶ | sub encode { |
|
Subroutine
encode: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 20 | 0 | my ($self, $content) = @_; | |
| 21 | 0 | return $self->_xml_parser->XMLin($content); | |
| 22 | } | ||
| 23 | |||
| 24 | 0 | ▶ | sub decode { |
|
Subroutine
decode: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 25 | 0 | my ($self, $content) = @_; | |
| 26 | 0 | return $self->_xml_parser->XMLout($content); | |
| 27 | } | ||
| 28 | |||
| 29 | 1 | 1; | |
| 30 | |||
| 31 | |||
| 32 | __END__ | ||