63 |
sub IMPLIED_DEFAULT () { 3 } |
sub IMPLIED_DEFAULT () { 3 } |
64 |
sub EXPLICIT_DEFAULT () { 4 } |
sub EXPLICIT_DEFAULT () { 4 } |
65 |
|
|
66 |
## The |Node| interface - attribute |
## |Node| attributes |
|
|
|
|
## Spec: |
|
|
## <http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#ID-F68D095> |
|
|
## <http://suika.fam.cx/gate/2005/sw/AttributeDefinition> |
|
67 |
|
|
68 |
sub node_name ($); # read-only trivial accessor |
sub node_name ($); # read-only trivial accessor |
69 |
|
|
70 |
## Spec: |
sub node_type () { 81002 } # ATTRIBUTE_DEFINITION_NODE |
|
## <http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#ID-111237558> |
|
|
|
|
|
sub node_type ($) { 81002 } # ATTRIBUTE_DEFINITION_NODE |
|
71 |
|
|
72 |
## Spec: |
*node_value = \&Message::DOM::Node::text_content; |
|
## <http://suika.fam.cx/gate/2005/sw/AttributeDefinition#anchor-2> |
|
|
|
|
|
## TODO: node_value |
|
73 |
|
|
74 |
## |Node| methods |
## |Node| methods |
75 |
|
|
135 |
package Message::DOM::Document; |
package Message::DOM::Document; |
136 |
|
|
137 |
sub create_attribute_definition ($$) { |
sub create_attribute_definition ($$) { |
138 |
|
if (${$_[0]}->{strict_error_checking}) { |
139 |
|
my $xv = $_[0]->xml_version; |
140 |
|
if (defined $xv) { |
141 |
|
if ($xv eq '1.0' and |
142 |
|
$_[1] =~ /\A\p{InXML_NameStartChar10}\p{InXMLNameChar10}*\z/) { |
143 |
|
# |
144 |
|
} elsif ($xv eq '1.1' and |
145 |
|
$_[1] =~ /\A\p{InXMLNameStartChar11}\p{InXMLNameChar11}*\z/) { |
146 |
|
# |
147 |
|
} else { |
148 |
|
report Message::DOM::DOMException |
149 |
|
-object => $_[0], |
150 |
|
-type => 'INVALID_CHARACTER_ERR', |
151 |
|
-subtype => 'MALFORMED_NAME_ERR'; |
152 |
|
} |
153 |
|
} |
154 |
|
} |
155 |
|
|
156 |
return Message::DOM::AttributeDefinition->____new (@_[0, 1]); |
return Message::DOM::AttributeDefinition->____new (@_[0, 1]); |
157 |
} # create_attribute_definition |
} # create_attribute_definition |
158 |
|
|