| 1 | package File::Serialize::Serializer::XML::Simple; | ||
| 2 | 7 | our $AUTHORITY = 'cpan:YANICK'; | |
| 3 | #ABSTRACT: XML::Simple serializer for File::Serialize | ||
| 4 | 7 | $File::Serialize::Serializer::XML::Simple::VERSION = '1.5.0'; | |
| 5 | 7 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | 7 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 7 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 9 | 7 | with 'File::Serialize::Serializer'; | |
| 10 | |||
| 11 | 0 | ▶ | sub extensions { qw/ xml / }; |
|
Subroutine
extensions: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 12 | |||
| 13 | sub serialize { | ||
| 14 | my( $self, $data, $options ) = @_; | ||
| 15 | XML::Simple->new->XMLout($data); | ||
| 16 | } | ||
| 17 | |||
| 18 | |||
| 19 | sub deserialize { | ||
| 20 | my( $self, $data, $options ) = @_; | ||
| 21 | XML::Simple->new->XMLin($data); | ||
| 22 | } | ||
| 23 | |||
| 24 | 7 | 1; | |
| 25 | |||
| 26 | __END__ | ||