.\" -*- mode: troff; coding: utf-8 -*-
.\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43)
.\"
.\" Standard preamble:
.\" ========================================================================
.de Sp \" Vertical space (when we can't use .PP)
.if t .sp .5v
.if n .sp
..
.de Vb \" Begin verbatim text
.ft CW
.nf
.ne \\$1
..
.de Ve \" End verbatim text
.ft R
.fi
..
.\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
.ie n \{\
. ds C` ""
. ds C' ""
'br\}
.el\{\
. ds C`
. ds C'
'br\}
.\"
.\" Escape single quotes in literal strings from groff's Unicode transform.
.ie \n(.g .ds Aq \(aq
.el .ds Aq '
.\"
.\" If the F register is >0, we'll generate index entries on stderr for
.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
.\" entries marked with X<> in POD. Of course, you'll have to process the
.\" output yourself in some meaningful fashion.
.\"
.\" Avoid warning from groff about undefined register 'F'.
.de IX
..
.nr rF 0
.if \n(.g .if rF .nr rF 1
.if (\n(rF:(\n(.g==0)) \{\
. if \nF \{\
. de IX
. tm Index:\\$1\t\\n%\t"\\$2"
..
. if !\nF==2 \{\
. nr % 0
. nr F 2
. \}
. \}
.\}
.rr rF
.\" ========================================================================
.\"
.IX Title "XML::Easy 3pm"
.TH XML::Easy 3pm 2024-03-31 "perl v5.38.2" "User Contributed Perl Documentation"
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
.\" way too many mistakes in technical documents.
.if n .ad l
.nh
.SH NAME
XML::Easy \- XML processing with a clean interface
.SH SYNOPSIS
.IX Header "SYNOPSIS"
.Vb 2
\& use XML::Easy::NodeBasics qw(xml_element xml_e_attribute);
\& use XML::Easy::Text qw(xml10_read_document xml10_write_document);
\&
\& $element = xml_element("a", { href => "there" }, "there");
\& $element = xml10_read_document(\*(Aqthere\*(Aq);
\&
\& $href = xml_e_attribute($element, "href");
\& $text = xml10_write_document($element);
\&
\& # see specific modules for many more functions
.Ve
.SH DESCRIPTION
.IX Header "DESCRIPTION"
XML::Easy is a collection of modules relating to the processing,
parsing, and serialisation of XML data. It is oriented towards the
use of XML to represent data for interchange purposes, rather than the
use of XML as markup of principally textual data. It does not perform
any schema processing, and does not interpret DTDs or any other kind
of schema. It adheres strictly to the XML specification, in all its
awkward details, except for the aforementioned DTDs.
.PP
XML::Easy strictly separates the in-program manipulation of XML
data from the processing of the textual form of XML. This shields
the XML user from the inconvenient and obscure aspects of XML syntax.
XML data nodes are mainly processed in a clean functional style, using
the XML::Easy::NodeBasics module. In the (very likely) event that
an application requires some more purpose-specific XML data processing
facilities, they are readily built on top of XML::Easy::NodeBasics,
retaining the abstraction from textual XML.
.PP
When XML must be handled in textual form, for input and output,
the XML::Easy::Text module supplies a parser and a serialiser.
The interfaces here, too, are functional in nature.
.PP
There are other modules for some ancillary aspects of XML processing.
.SH MODULES
.IX Header "MODULES"
The modules in the XML::Easy distribution are:
.IP XML::Easy 4
.IX Item "XML::Easy"
This document. For historical reasons, this can also be loaded as
a module, and (though it is deprecated) some of the functions from
XML::Easy::Text can be imported from here.
.IP XML::Easy::Classify 4
.IX Item "XML::Easy::Classify"
This module provides various type-testing functions, relating to data
types used in the XML::Easy ensemble. These are mainly intended to be
used to enforce validity of data being processed by XML-related functions.
.IP XML::Easy::Content 4
.IX Item "XML::Easy::Content"
.PD 0
.IP XML::Easy::Element 4
.IX Item "XML::Easy::Element"
.PD
These are classes used to represent XML data for general manipulation.
Objects of these classes hold the meaningful content of the data,
independent of textual representation. The data in these nodes cannot
be modified: different data requires new nodes.
.IP XML::Easy::NodeBasics 4
.IX Item "XML::Easy::NodeBasics"
This module supplies functions concerned with the creation, examination,
and other manipulation of XML data nodes (content chunks and elements).
The nodes are dumb data objects, best manipulated using plain functions
such as the ones in this module.
.IP XML::Easy::Syntax 4
.IX Item "XML::Easy::Syntax"
This module supplies Perl regular expressions describing the grammar of
XML 1.0. This is intended to support doing irregular things with XML,
rather than for normal parsing.
.IP XML::Easy::Text 4
.IX Item "XML::Easy::Text"
This module supplies functions that parse and serialise XML data as text
according to the XML 1.0 specification.
.SH "OTHER DISTRIBUTIONS"
.IX Header "OTHER DISTRIBUTIONS"
Other CPAN distributions that work with XML::Easy are:
.IP Test::XML::Easy 4
.IX Item "Test::XML::Easy"
A testing tool, providing Test::More\-style functions that check
whether XML nodes are as expected.
.IP XML::Easy::ProceduralWriter 4
.IX Item "XML::Easy::ProceduralWriter"
Provides a way to construct XML data nodes by procedural code.
Some programmers will find this more comfortable than the functional
style offered by XML::Easy::NodeBasics.
.IP XML::Easy::SimpleSchemaUtil 4
.IX Item "XML::Easy::SimpleSchemaUtil"
Helps to parse things that are encoded in XML in common ways.
.ie n .IP """XML::Easy::Transform::""" 4
.el .IP \f(CWXML::Easy::Transform::\fR 4
.IX Item "XML::Easy::Transform::"
This namespace exists to contain modules that perform transformations
on XML documents, or parts thereof, in the form of XML::Easy::Element
and XML::Easy::Content nodes.
.SH "SEE ALSO"
.IX Header "SEE ALSO"
XML::Easy::Classify,
XML::Easy::NodeBasics,
XML::Easy::Syntax,
XML::Easy::Text,
.SH AUTHOR
.IX Header "AUTHOR"
Andrew Main (Zefram)
.SH COPYRIGHT
.IX Header "COPYRIGHT"
Copyright (C) 2008, 2009 PhotoBox Ltd
.PP
Copyright (C) 2009, 2010, 2011, 2017
Andrew Main (Zefram)
.SH LICENSE
.IX Header "LICENSE"
This module is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.