1DOM-ecmascript(3)     User Contributed Perl Documentation    DOM-ecmascript(3)
2
3
4

XML::Grove and DOM Level One

6       XML::Grove is similar in concept to the ECMA Script Language Binding to
7       DOM Level 1 Core (Appendix E of the DOM Recommendation).
8
9       <http://www.w3.org/TR/REC-DOM-Level-1/ecma-script-language-binding.html>
10
11       The ECMA Script Language Binding presents DOM properties as ECMA Script
12       object properties.  The same is true for XML::Grove, XML::Grove
13       presents DOM properties as Perl blessed hashes.
14
15       The biggest difference between the ECMA Script Language Binding and
16       XML::Grove is that XML::Grove uses a Perl hash for nodes, Perl arrays
17       for NodeLists, Perl hashes for NamedNodeLists so those object classes
18       don't exist in XML::Grove.  Because those classes don't exist, you use
19       ordinary Perl syntax for manipulating the DOM properties (lists and
20       named node lists) instead of methods like `"nextSibling()"' or
21       `"replaceChild()"'.  Element attributes in XML::Grove are stored in
22       Perl hashes; attribute types are available through the document object.
23
24       Another difference is that XML::Grove attempts to marry the PerlSAX and
25       DOM naming so that less (no?) name-changing occurs between using
26       PerlSAX interfaces and filters and DOM modules.  Where conflicts occur,
27       the PerlSAX naming is used.
28
29       XML::Grove uses a blessed hash for nodes, so the node type is available
30       using Perl's `"ref()"' instead of using a `"nodeType()"' method and all
31       class names are prefixed with `"XML::Grove::"'.
32
33       The following object descriptions are the most basic and common
34       provided by many PerlSAX parsers.  PerlSAX parsers often provide
35       additional properties or objects, refer to your PerlSAX parser
36       documentation for details.
37

Document Object Model Level 1 Core

39   Object XML::Grove::Document
40       Contents    The children of this object.  This property is an array.
41
42       Entities    The entities declared in this document.  This property is a
43                   hash of XML::Grove::Entity objects keyed by entity name.
44
45       Notations   The notations declared in this document.  This property is
46                   a hash of XML::Grove::Notation objects keyed by notation
47                   name.
48
49   Object XML::Grove::Element
50       Name        The tag type name for this element.  This property is a
51                   string.
52
53       Attributes  The attributes for this element.  This property is a hash
54                   and it's hash values are strings (or arrays with some grove
55                   builders).
56
57       Contents    The children of this object.  This property is an array of
58                   XML::Grove objects.
59
60   Object XML::Grove::Characters
61       Data        The text of the character data.  This property is a string.
62
63   Object XML::Grove::Comment
64       Data        The text of the character data.  This property is a string.
65
66   Object XML::Grove::CData
67       The "CData" object is called a "CDATASection" in DOM.
68
69       Data        The text of the character data.  This property is a string.
70
71   Object XML::Grove::Notation
72       Name        The name of this notation.  This property is a string.
73
74       SystemId    The system identifier of this notation.  This property is a
75                   string.
76
77       PublicId    The public identifier of this notation.  This property is a
78                   string.
79
80   Object XML::Grove::Entity
81       Name        The name of this entity.  This property is a string.
82
83       SystemId    The system identifier of this notation.  This property is a
84                   string.
85
86       PublicId    The public identifier of this notation.  This property is a
87                   string.
88
89       Notation    The notation declared for this entity.  This property is
90                   either the name of the notation as a string or an
91                   "XML::Grove::Notation" object.
92
93   Object XML::Grove::PI
94       The "PI" object is called a "ProcessingInstruction" in DOM.
95
96       Target      The target of the processing instruction.  This property is
97                   a string.
98
99       Data        The text of the processing instruction.  This property is a
100                   string.
101
102
103
104perl v5.28.0                      1999-05-26                 DOM-ecmascript(3)
Impressum