14 |
|
|
15 |
=head1 VERSION |
=head1 VERSION |
16 |
|
|
17 |
Version 0.01 |
Version 0.02 |
18 |
|
|
19 |
=cut |
=cut |
20 |
|
|
21 |
our $VERSION = '0.01'; |
our $VERSION = '0.02'; |
22 |
|
|
23 |
=head1 SYNOPSIS |
=head1 SYNOPSIS |
24 |
|
|
44 |
|
|
45 |
C<xml_file> defines path to normalize XML. |
C<xml_file> defines path to normalize XML. |
46 |
|
|
47 |
|
C<tags> define additional tags that can be forced (and an be array). |
48 |
|
|
49 |
=cut |
=cut |
50 |
|
|
51 |
sub open { |
sub open { |
68 |
|
|
69 |
$self->{'import_xml_file'} = $xml_file; |
$self->{'import_xml_file'} = $xml_file; |
70 |
|
|
71 |
|
my @force_array = [ $self->{'tag'}, 'config', 'format' ]; |
72 |
|
push @force_array, $self->{'tags'} if ($self->{'tags'}); |
73 |
|
|
74 |
$self->{'import_xml'} = XMLin($xml_file, |
$self->{'import_xml'} = XMLin($xml_file, |
75 |
ForceArray => [ $self->{'tag'}, $self->{'tags'}, 'config', 'format' ], |
ForceArray => @force_array, |
76 |
ForceContent => 1, |
ForceContent => 1, |
77 |
); |
); |
78 |
|
|