/[suikacvs]/messaging/manakai/lib/Message/DOM/DOMException.pm
Suika

Contents of /messaging/manakai/lib/Message/DOM/DOMException.pm

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.15 - (hide annotations) (download)
Mon Sep 24 10:16:14 2007 UTC (17 years, 2 months ago) by wakaba
Branch: MAIN
CVS Tags: manakai-release-0-4-0
Changes since 1.14: +14 -3 lines
++ manakai/lib/Message/DOM/ChangeLog	24 Sep 2007 10:15:28 -0000
2007-09-24  Wakaba  <wakaba@suika.fam.cx>

	* DOMException.pm (SYNTAX_ERR): New subtype is defined.
	(UNDECLARED_PREFIX_ERR): New subtype is defined.

	* Document.pm (Document): Implements the |DocumentSelector|
	interface.

	* Element.pm (Element): Implements the |ElementSelector|
	interface.

	* Node.pm (Node): Implements the |NSResolver| interface.

	* SelectorsAPI.pm: Now (hopefully) conform to the Selectors
	API Editor's Draft (only |query_selector_all| on |Document|,
	with limited selectors syntax support, though).

++ manakai/t/ChangeLog	24 Sep 2007 10:16:05 -0000
2007-09-24  Wakaba  <wakaba@suika.fam.cx>

	* selectors-test-1.dat: New tests for pseudo-elements
	are added.

1 wakaba 1.1 package Message::DOM::DOMException;
2     use strict;
3 wakaba 1.15 our $VERSION=do{my @r=(q$Revision: 1.14 $=~/\d+/g);sprintf "%d."."%02d" x $#r,@r};
4 wakaba 1.1 push our @ISA, 'Message::Util::Error', 'Message::IF::DOMException';
5     require Message::Util::Error;
6    
7     sub ___error_def () {+{
8 wakaba 1.11 INDEX_SIZE_ERR => {
9     -code => 1,
10     -subtype => {
11     INDEX_OUT_OF_BOUND_ERR => {
12 wakaba 1.12 -description => q(Specified index is outside of the bounds),
13 wakaba 1.11 },
14     },
15     },
16 wakaba 1.13 # DOMSTRING_SIZE_ERR == 2
17 wakaba 1.9 HIERARCHY_REQUEST_ERR => {
18     -code => 3,
19     -subtype => {
20     ANCESTOR_NODE_ERR => {
21     -description => q(Specified node is an ancestor of the node or the node itself),
22     },
23     CHILD_NODE_TYPE_ERR => {
24     -description => q(This type of node cannot be inserted to this point),
25     },
26 wakaba 1.10 INUSE_DEFINITION_ERR => {
27     -description => q(The node is already in use),
28     },
29 wakaba 1.9 },
30     },
31 wakaba 1.4 WRONG_DOCUMENT_ERR => {
32     -code => 4,
33 wakaba 1.9 -subtype => {
34     EXTERNAL_OBJECT_ERR => {
35     -description => q(Can't insert into different document),
36     },
37     INUSE_DOCTYPE_ERR => {
38     -description => q(Document type is already in use),
39     },
40 wakaba 1.8 },
41 wakaba 1.4 },
42 wakaba 1.7 INVALID_CHARACTER_ERR => {
43     -code => 5,
44     -subtype => {
45     MALFORMED_NAME_ERR => {
46     -description => q(Not a legal XML |Name|),
47     },
48     },
49     },
50 wakaba 1.13 # NO_DATA_ALLOWED_ERR == 6
51 wakaba 1.1 NO_MODIFICATION_ALLOWED_ERR => {
52     -code => 7,
53     -subtype => {
54 wakaba 1.3 READ_ONLY_NODE_ERR => {
55     -description => q(Can't modify read-only node),
56     },
57 wakaba 1.1 READ_ONLY_NODE_LIST_ERR => {
58     -description => q(Can't modify read-only node list),
59     },
60     },
61     },
62 wakaba 1.9 NOT_FOUND_ERR => {
63     -code => 8,
64     -subtype => {
65     NOT_CHILD_ERR => {
66     -description => q(Not a child of this node),
67     },
68 wakaba 1.13 UNRECOGNIZED_CONFIGURATION_PARAMETER_ERR => {
69     -description => q(Unrecognized configuration parameter is specified),
70     },
71 wakaba 1.9 },
72     },
73 wakaba 1.4 NOT_SUPPORTED_ERR => {
74     -code => 9,
75     -subtype => {
76 wakaba 1.6 ADOPT_NODE_TYPE_NOT_SUPPORTED_ERR => {
77     -description => q(Can't adopt specified type of node),
78     },
79 wakaba 1.5 CLONE_NODE_TYPE_NOT_SUPPORTED_ERR => {
80     -description => q(Can't clone specified type of node),
81     },
82 wakaba 1.14 CONFIGURATION_PARAMETER_VALUE_ERR => {
83 wakaba 1.13 -description => q(Can't set the value to the configuration parameter),
84     },
85 wakaba 1.4 NON_HTML_OPERATION_ERR => {
86     -description => q(Can't apply to HTML document),
87     },
88 wakaba 1.14 NULLPO_ERR => {
89     -description => q(NULLPO),
90     },
91 wakaba 1.4 UNKNOWN_XML_VERSION_ERR => {
92     -description => q(Specified version of XML is not supported),
93     },
94     },
95     },
96     INUSE_ATTRIBUTE_ERR => {
97     -code => 10,
98     -description => q(Attribute is already in use),
99     },
100 wakaba 1.13 # INVALID_STATE_ERR == 11
101 wakaba 1.15 SYNTAX_ERR => {
102     -code => 12,
103     -subtype => {
104     INVALID_SELECTORS_ERR => {
105     -description => q(Invalid group of selectors),
106     },
107     },
108     },
109 wakaba 1.13 # INVALID_MODIFICATION_ERR == 13
110 wakaba 1.7 NAMESPACE_ERR => {
111     -code => 14,
112     -subtype => {
113     MALFORMED_QNAME_ERR => {
114     -description => q(Malformed XML qualified name),
115     },
116     NONXMLNSPREFIX_XMLNSNS_ERR => {
117     -description => q(Namespace prefix "xmlns" must be used for namespace URI <http://www.w3.org/2000/xmlns/>),
118     },
119     PREFIXED_NULLNS_ERR => {
120     -description => q(A namespace prefix is specified while namespace URI is null),
121     },
122 wakaba 1.8 QNAME_NULLNS_ERR => {
123     -description => q(Qualified name is not specified),
124     },
125 wakaba 1.15 UNDECLARED_PREFIX_ERR => {
126     -description => q(Undeclared prefix
127     "%p (name => {namespace_prefix});"),
128     },
129 wakaba 1.7 XMLNS_NONXMLNSNS_ERR => {
130     -description => q(Qualified name "xmlns" can only be used with namespace URI <http://www.w3.org/2000/xmlns/>),
131     },
132     XMLNSPREFIX_NONXMLNSNS_ERR => {
133     -description => q(Namespace prefix "xmlns" cannot be used for namespace URI other than <http://www.w3.org/2000/xmlns/>),
134     },
135     XMLPREFIX_NONXMLNS_ERR => {
136     -description => q(Namespace prefix "xml" cannot be used for namespace URI other than <http://www.w3.org/XML/1998/namespace>),
137     },
138     },
139     },
140 wakaba 1.13 # INVALID_ACCESS_ERR == 15
141     # VALIDATION_ERR == 16
142     TYPE_MISMATCH_ERR => {
143     -code => 17,
144     -subtype => {
145     CONFIGURATION_PARAMETER_TYPE_ERR => {
146     -description => q(The value type for this configuration parameter is incompatible with the specified value),
147     },
148     },
149     },
150 wakaba 1.1 }} # ___error_def
151    
152     package Message::IF::DOMException;
153 wakaba 1.2 push our @ISA, 'Message::Util::Error';
154 wakaba 1.1
155     ## DOM1
156     sub INDEX_SIZE_ERR () { 1 }
157     sub DOMSTRING_SIZE_ERR () { 2 }
158     sub HIERARCHY_REQUEST_ERR () { 3 }
159     sub WRONG_DOCUMENT_ERR () { 4 }
160     sub INVALID_CHARACTER_ERR () { 5 }
161     sub NO_DATA_ALLOWED_ERR () { 6 }
162     sub NO_MODIFICATION_ALLOWED_ERR () { 7 }
163     sub NOT_FOUND_ERR () { 8 }
164     sub NOT_SUPPORTED_ERR () { 9 }
165     sub INUSE_ATTRIBUTE_ERR () { 10 }
166     ## DOM2
167     sub INVALID_STATE_ERR () { 11 }
168     sub SYNTAX_ERR () { 12 }
169     sub INVALID_MODIFICATION_ERR () { 13 }
170     sub NAMESPACE_ERR () { 14 }
171     sub INVALID_ACCESS_ERR () { 15 }
172     ## DOM3
173     sub VALIDATION_ERR () { 16 }
174     sub TYPE_MISMATCH_ERR () { 17 }
175    
176     =head1 LICENSE
177    
178     Copyright 2007 Wakaba <w@suika.fam.cx>
179    
180     This program is free software; you can redistribute it and/or
181     modify it under the same terms as Perl itself.
182    
183     =cut
184    
185     1;
186 wakaba 1.15 ## $Date: 2007/07/14 16:32:28 $

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24