line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package File::Serialize::Serializer::YAML::XS; |
2
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:YANICK'; |
3
|
|
|
|
|
|
|
#ABSTRACT: YAML:XS serializer for File::Serialize |
4
|
|
|
|
|
|
|
$File::Serialize::Serializer::YAML::XS::VERSION = '1.5.0'; |
5
|
6
|
|
|
6
|
|
4861
|
use strict; |
|
6
|
|
|
|
|
11
|
|
|
6
|
|
|
|
|
169
|
|
6
|
6
|
|
|
6
|
|
29
|
use warnings; |
|
6
|
|
|
|
|
12
|
|
|
6
|
|
|
|
|
140
|
|
7
|
|
|
|
|
|
|
|
8
|
6
|
|
|
6
|
|
27
|
use Moo; |
|
6
|
|
|
|
|
10
|
|
|
6
|
|
|
|
|
38
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
with 'File::Serialize::Serializer'; |
11
|
|
|
|
|
|
|
|
12
|
0
|
|
|
0
|
1
|
0
|
sub extensions { qw/ yml yaml / }; |
13
|
|
|
|
|
|
|
|
14
|
56
|
|
|
56
|
1
|
156
|
sub precedence { 110 } |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub serialize { |
17
|
|
|
|
|
|
|
my( $self, $data, $options ) = @_; |
18
|
|
|
|
|
|
|
YAML::XS::Dump($data); |
19
|
|
|
|
|
|
|
} |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
sub deserialize { |
23
|
|
|
|
|
|
|
my( $self, $data, $options ) = @_; |
24
|
|
|
|
|
|
|
YAML::XS::Load($data); |
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
1; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
__END__ |