NAME
XML::LibXSLT::Quick - a quicker interface to XML::LibXSLT
SYNOPSIS
use XML::LibXSLT::Quick ();
my $stylesheet =
XML::LibXSLT::Quick->new( { location => 'example/1.xsl', } );
my $xml1_text = _utf8_slurp('example/1.xml');
my $out_fn = 'foo.xml';
$stylesheet->generic_transform(
+{
type => 'file',
path => $out_fn,
},
$xml1_text,
);
DESCRIPTION
This is a module that wraps XML::LibXSLT with an easier to use interface.
METHODS
XML::LibXSLT::Quick->new({ location=>"./xslt/my.xslt", });
TBD.
$obj->stylesheet()
The result of parse_stylesheet().
$obj->xml_parser()
The XML::LibXML instance.
$obj->generic_transform($dest, $source)
To be discussed.
See t/using-quick-wrapper.t
.
$obj->output_as_chars($dom)
$obj->transform(...)
$obj->transform_into_chars(...)
Delegating from $obj->stylesheet() . See XML::LibXSLT .
SEE ALSO
XML::LibXSLT::Easy by Yuval Kogman - requires some MooseX modules.
XML::LibXSLT - used as the backend of this module.
COPYRIGHT & LICENSE
Copyright 2022 by Shlomi Fish
This program is distributed under the MIT / Expat License: http://www.opensource.org/licenses/mit-license.php
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.