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.4.0'; |
5
|
6
|
|
|
6
|
|
4878
|
use strict; |
|
6
|
|
|
|
|
14
|
|
|
6
|
|
|
|
|
168
|
|
6
|
6
|
|
|
6
|
|
29
|
use warnings; |
|
6
|
|
|
|
|
13
|
|
|
6
|
|
|
|
|
143
|
|
7
|
|
|
|
|
|
|
|
8
|
6
|
|
|
6
|
|
30
|
use Moo; |
|
6
|
|
|
|
|
11
|
|
|
6
|
|
|
|
|
30
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
with 'File::Serialize::Serializer'; |
11
|
|
|
|
|
|
|
|
12
|
0
|
|
|
0
|
1
|
0
|
sub extensions { qw/ yml yaml / }; |
13
|
|
|
|
|
|
|
|
14
|
56
|
|
|
56
|
1
|
185
|
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__ |