equal
deleted
inserted
replaced
1 =head1 NAME |
|
2 |
|
3 XML::DOM::AttlistDecl - An XML ATTLIST declaration in XML::DOM |
|
4 |
|
5 =head1 DESCRIPTION |
|
6 |
|
7 XML::DOM::AttlistDecl extends L<XML::DOM::Node> but is not part of the |
|
8 DOM Level 1 specification. |
|
9 |
|
10 This node represents an ATTLIST declaration, e.g. |
|
11 |
|
12 <!ATTLIST person |
|
13 sex (male|female) #REQUIRED |
|
14 hair CDATA "bold" |
|
15 eyes (none|one|two) "two" |
|
16 species (human) #FIXED "human"> |
|
17 |
|
18 Each attribute definition is stored a separate AttDef node. The AttDef nodes can |
|
19 be retrieved with getAttDef and added with addAttDef. |
|
20 (The AttDef nodes are stored in a NamedNodeMap internally.) |
|
21 |
|
22 =head2 METHODS |
|
23 |
|
24 =over 4 |
|
25 |
|
26 =item getName |
|
27 |
|
28 Returns the Element tagName. |
|
29 |
|
30 =item getAttDef (attrName) |
|
31 |
|
32 Returns the AttDef node for the attribute with the specified name. |
|
33 |
|
34 =item addAttDef (attrName, type, default, [ fixed ]) |
|
35 |
|
36 Adds a AttDef node for the attribute with the specified name. |
|
37 |
|
38 Parameters: |
|
39 I<attrName> the attribute name. |
|
40 I<type> the attribute type (e.g. "CDATA" or "(male|female)".) |
|
41 I<default> the default value enclosed in quotes (!), the string #IMPLIED or |
|
42 the string #REQUIRED. |
|
43 I<fixed> whether the attribute is '#FIXED' (default is 0.) |
|
44 |
|
45 =back |
|