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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.8 - (hide annotations) (download)
Sat Dec 2 12:46:19 2006 UTC (17 years, 11 months ago) by wakaba
Branch: MAIN
Changes since 1.7: +18 -18 lines
++ manakai/t/ChangeLog	2 Dec 2006 12:46:13 -0000
2006-12-02  Wakaba  <wakaba@suika.fam.cx>

	* Makefile (dom-DOMString.t): New test.

++ manakai/bin/ChangeLog	2 Dec 2006 12:35:25 -0000
2006-12-02  Wakaba  <wakaba@suika.fam.cx>

	* daf.pl: Call |get_dom_implementation|
	instead of obsolete |get_implementation|.

	* grep-dis.pl: |lib/manakai/*.pl| is added.

++ manakai/lib/Message/Util/ChangeLog	2 Dec 2006 12:45:49 -0000
2006-12-02  Wakaba  <wakaba@suika.fam.cx>

	* Makefile: |lib/Message/DOM/DOMString.pm| is added.

++ manakai/lib/Message/DOM/ChangeLog	2 Dec 2006 12:45:20 -0000
2006-12-02  Wakaba  <wakaba@suika.fam.cx>

	* DOMString.dis: New module.

	* DOMString.pm: New file.

	* DOMCore.dis (min): Moved from |DOMFeature.dis|.
	(ImplementationRegistryVariable): Moved from |DOMFeature.dis|.
	Now it references the |DOMImplementationRegistry| object.
	(DOMImplementationRegistryVariable): Moved from |DOMMain.dis|.
	(DOMImplementationRegistry): New interface and
	class, reformed from |ImplementationRegistry| in |DOMFeature.dis|
	and |DOMImplementationRegistry| in |DOMMain.dis|.  Note
	that the class no longer support |get_implementation|
	and |get_implementation_list| methods from
	the |ImplementationRegistry| interface.
	(DOMImplementationList): Class implemented; no
	longer inherits from |ImplementationList|.
	(DOMImplementationSource): Class implemented; no
	longer inherits from |ImplementationSource|.  Note that
	the class no longer support |get_implementation|
	and |get_implementation_list| methods from
	the |ImplementationSource| interface.
	(DOMStringList): Removed.

	* DOMFeature.dis (min, ManakaiDOM:DOMHTMLFeature,
	ManakaiDOM:DOMEventsFeature, ManakaiDOM:DOMXMLFeature,
	ManakaiDOM:DOMXMLFeatureXML11, most part of
	documentation for obsolete DOM Level 3 Minimum Implementation
	module, obsolete property name aliases,
	ImplemenationRegistryVar, ImplementationRegistry,
	DEBUG, MIString, ImplementationList, ImplementationSource,
	ManakaiDOM:implID): Removed.

	* DOMMain.dis (Redefine, RedefinedBy, Redefined): Removed.
	(DOMString): Removed.
	(DOMImplementationRegistryVar, DOMImplementationRegistry): Removed.

	* Makefile: |DOMString.pm| is added.

	* TreeCore.dis (is_default_namespace): |null| was
	returned where a false is expected (|null| is
	a false in Perl, but real |false| is appropriate here).

1 wakaba 1.1 #!/usr/bin/perl
2     ## This file is automatically generated
3 wakaba 1.8 ## at 2006-12-02T09:52:37+00:00,
4     ## from file "../lib/Message/DOM/CharacterData.dis",
5 wakaba 1.1 ## module <http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom#ManakaiDOM.CharacterData>,
6     ## for <http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom#ManakaiDOMLatest>.
7     ## Don't edit by hand!
8     use strict;
9     require Message::DOM::DOMCore;
10 wakaba 1.7 require Message::DOM::Document;
11 wakaba 1.1 require Message::DOM::TreeCore;
12     require Message::Util::Error::DOMException;
13     package Message::DOM::CharacterData;
14 wakaba 1.8 our $VERSION = 20061202.0952;
15 wakaba 1.7 package Message::DOM::CharacterData::ManakaiDOMDocumentCharacterData;
16 wakaba 1.8 our $VERSION = 20061202.0952;
17 wakaba 1.7 push @Message::DOM::Document::ManakaiDOMDocument::ISA, q<Message::DOM::CharacterData::ManakaiDOMDocumentCharacterData> unless Message::DOM::Document::ManakaiDOMDocument->isa (q<Message::DOM::CharacterData::ManakaiDOMDocumentCharacterData>);
18     sub create_text_node ($$) {
19     my ($self, $data) = @_;
20     my $r;
21    
22     {
23    
24     my
25     $bag =
26     $self->{'b'}
27     ;
28     my $stem;
29    
30    
31     {
32    
33    
34     $stem = 'Message::DOM::CharacterData::ManakaiDOMText'->___create_node_stem ($bag, {
35    
36     'rc'
37     => 0,
38    
39     'id'
40     => \
41     (
42     'tag:suika.fam.cx,2005-09:' . time . ':' . $$ . ':' .
43     (++$Message::Util::ManakaiNode::UniqueIDN)
44     )
45     ,
46     }, {
47     'od' => $self,
48     'con' => \$data,
49     });
50    
51    
52     {
53    
54     if
55     (defined 'Message::DOM::CharacterData::ManakaiDOMText') {
56     if (ref 'Message::DOM::CharacterData::ManakaiDOMText' eq 'SCALAR') {
57     $stem->{'cls'} = 'Message::DOM::CharacterData::ManakaiDOMText';
58     } elsif (defined $Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMText'}) {
59     $stem->{'cls'} = $Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMText'};
60     } else {
61     require Scalar::Util;
62     $stem->{'cls'} = $Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMText'} = \('Message::DOM::CharacterData::ManakaiDOMText');
63     Scalar::Util::weaken ($Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMText'});
64     }
65     } else {
66     CORE::delete $stem->{'cls'};
67     }
68    
69    
70     }
71    
72     ;
73     $bag->{${$stem->{
74     'id'
75     }}} = $stem;
76    
77    
78     }
79    
80     ;
81    
82    
83     {
84    
85    
86     $r = ${$stem->{
87     'cls'
88     }}->___create_node_ref ({
89    
90     'id'
91     => $stem->{
92     'id'
93     },
94    
95     'b'
96     => $bag,
97     }, {
98     });
99     $stem->{
100     'rc'
101     }++;
102    
103    
104     }
105    
106     ;
107    
108    
109     }
110     $r}
111     sub create_comment ($$) {
112     my ($self, $data) = @_;
113     my $r;
114    
115     {
116    
117     my
118     $bag =
119     $self->{'b'}
120     ;
121     my $stem;
122    
123    
124     {
125    
126    
127     $stem = 'Message::DOM::CharacterData::ManakaiDOMComment'->___create_node_stem ($bag, {
128    
129     'rc'
130     => 0,
131    
132     'id'
133     => \
134     (
135     'tag:suika.fam.cx,2005-09:' . time . ':' . $$ . ':' .
136     (++$Message::Util::ManakaiNode::UniqueIDN)
137     )
138     ,
139     }, {
140     'od' => $self,
141     'con' => \$data,
142     });
143    
144    
145     {
146    
147     if
148     (defined 'Message::DOM::CharacterData::ManakaiDOMComment') {
149     if (ref 'Message::DOM::CharacterData::ManakaiDOMComment' eq 'SCALAR') {
150     $stem->{'cls'} = 'Message::DOM::CharacterData::ManakaiDOMComment';
151     } elsif (defined $Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMComment'}) {
152     $stem->{'cls'} = $Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMComment'};
153     } else {
154     require Scalar::Util;
155     $stem->{'cls'} = $Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMComment'} = \('Message::DOM::CharacterData::ManakaiDOMComment');
156     Scalar::Util::weaken ($Message::Util::ManakaiStringRef::Value{'Message::DOM::CharacterData::ManakaiDOMComment'});
157     }
158     } else {
159     CORE::delete $stem->{'cls'};
160     }
161    
162    
163     }
164    
165     ;
166     $bag->{${$stem->{
167     'id'
168     }}} = $stem;
169    
170    
171     }
172    
173     ;
174    
175    
176     {
177    
178    
179     $r = ${$stem->{
180     'cls'
181     }}->___create_node_ref ({
182    
183     'id'
184     => $stem->{
185     'id'
186     },
187    
188     'b'
189     => $bag,
190     }, {
191     });
192     $stem->{
193     'rc'
194     }++;
195    
196    
197     }
198    
199     ;
200    
201    
202     }
203     $r}
204     $Message::DOM::DOMFeature::ClassInfo->{q<Message::DOM::CharacterData::ManakaiDOMDocumentCharacterData>}->{has_feature} = {};
205     $Message::DOM::ClassPoint{q<Message::DOM::CharacterData::ManakaiDOMDocumentCharacterData>} = 0;
206 wakaba 1.1 package Message::DOM::IFLatest::CharacterData;
207 wakaba 1.8 our $VERSION = 20061202.0952;
208 wakaba 1.1 package Message::DOM::CharacterData::ManakaiDOMCharacterData;
209 wakaba 1.8 our $VERSION = 20061202.0952;
210 wakaba 1.1 push our @ISA, 'Message::DOM::TreeCore::ManakaiDOMNode',
211     'Message::DOM::IF::CharacterData',
212     'Message::DOM::IF::Node',
213     'Message::DOM::IFLatest::CharacterData',
214     'Message::DOM::IFLatest::Node',
215     'Message::DOM::IFLatest::StringExtended',
216     'Message::DOM::IFLevel1::CharacterData',
217     'Message::DOM::IFLevel1::Node',
218     'Message::DOM::IFLevel2::CharacterData',
219     'Message::DOM::IFLevel2::Node',
220     'Message::DOM::IFLevel3::CharacterData',
221     'Message::DOM::IFLevel3::Node';
222 wakaba 1.2 use Message::Util::Error;
223 wakaba 1.1 sub ___create_node_stem ($$$$) {
224     my ($self, $bag, $obj, $opt) = @_;
225     my $r = {};
226    
227     {
228    
229    
230     $obj->{
231     'con'
232     } = $opt->{
233     'con'
234     };
235    
236    
237     {
238    
239    
240     $obj->{'od'} = $opt->{'od'}->{
241     'id'
242     };
243     $bag->{${$opt->{'od'}->{
244     'id'
245     }}}
246     ->{'do'}->{${$obj->{
247     'id'
248     }}}
249     = $obj->{
250     'id'
251     };
252    
253    
254     }
255    
256     ;
257     $r = $obj;
258    
259    
260     }
261     $r}
262     sub child_nodes ($;$) {
263     if (@_ == 1) {my ($self) = @_;
264     my $r;
265    
266     {
267    
268    
269     {
270    
271    
272     $r = bless [],
273     'Message::DOM::TreeCore::ManakaiDOMEmptyNodeList'
274     ;
275    
276    
277     }
278    
279     ;
280    
281    
282     }
283     $r;
284     } else {my ($self) = @_;
285     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'child_nodes';
286     }
287     }
288     sub append_child ($$) {
289     my ($self, $newChild) = @_;
290     my $r;
291    
292     {
293    
294     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'HIERARCHY_REQUEST_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'append_child', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#HIERARCHY_BAD_TYPE', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'newChild', 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#node' => $newChild;
295    
296     ;
297    
298    
299     }
300     $r}
301     sub insert_before ($$;$) {
302     my ($self, $newChild, $refChild) = @_;
303     my $r;
304    
305     {
306    
307     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'HIERARCHY_REQUEST_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'insert_before', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#HIERARCHY_BAD_TYPE', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'newChild', 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#node' => $newChild;
308    
309     ;
310    
311    
312     }
313     $r}
314     sub replace_child ($$$) {
315     my ($self, $newChild, $oldChild) = @_;
316     my $r;
317    
318     {
319    
320     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'HIERARCHY_REQUEST_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'replace_child', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#HIERARCHY_BAD_TYPE', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'newChild', 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#node' => $newChild;
321    
322     ;
323    
324    
325     }
326     $r}
327     sub manakai_append_text ($$) {
328     my ($self, $string) = @_;
329     my $r;
330    
331     {
332    
333    
334     {
335    
336     local $Error::Depth = $Error::Depth + 1;
337    
338     {
339    
340    
341     if
342     ($self->
343     owner_document
344    
345     ->
346     strict_error_checking and
347    
348     $self->
349     manakai_read_only
350     ) {
351    
352    
353     {
354    
355     local $Error::Depth = $Error::Depth - 1;
356    
357     {
358    
359     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'manakai_append_text', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData';
360    
361    
362     }
363    
364    
365     ;}
366    
367     ;
368     }
369     my $v;
370    
371    
372     {
373    
374    
375     $v = $self->{
376     'b'
377     }->{${$self->{
378     'id'
379     }}}
380     ->{'con'};
381    
382    
383     }
384    
385     ;
386     $$v .= ref $string eq 'SCALAR' ? $$string : $string;
387     $r = $self;
388    
389    
390    
391     }
392    
393    
394     ;}
395    
396     ;
397    
398    
399     }
400     $r}
401     sub node_value ($;$) {
402     if (@_ == 1) {my ($self) = @_;
403 wakaba 1.8 my $r;
404 wakaba 1.1
405     {
406    
407     my
408     $v;
409    
410    
411     {
412    
413    
414     $v = $self->{
415     'b'
416     }->{${$self->{
417     'id'
418     }}}
419     ->{'con'};
420    
421    
422     }
423    
424     ;
425     $r = $$v;
426    
427    
428     }
429     $r;
430     } else {my ($self, $given) = @_;
431    
432     {
433    
434    
435     {
436    
437     if
438     ($self->
439     manakai_read_only
440     ) {
441    
442     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
443    
444     ;
445     }
446    
447    
448     }
449    
450     ;
451     my $v;
452    
453    
454     {
455    
456    
457     $v = $self->{
458     'b'
459     }->{${$self->{
460     'id'
461     }}}
462     ->{'con'};
463    
464    
465     }
466    
467     ;
468     $$v = defined $given ? $given : '';
469     ## NOTE: Setting NULL is supported for
470     ## compatibility with |textContent|.
471    
472    
473     }
474     }
475     }
476     sub text_content ($;$) {
477     if (@_ == 1) {my ($self) = @_;
478 wakaba 1.8 my $r;
479 wakaba 1.1
480     {
481    
482     my
483     $v;
484    
485    
486     {
487    
488    
489     $v = $self->{
490     'b'
491     }->{${$self->{
492     'id'
493     }}}
494     ->{'con'};
495    
496    
497     }
498    
499     ;
500     $r = $$v;
501    
502    
503     }
504     $r;
505     } else {my ($self, $given) = @_;
506    
507     {
508    
509    
510     {
511    
512     if
513     ($self->
514     manakai_read_only
515     ) {
516    
517     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
518    
519     ;
520     }
521    
522    
523     }
524    
525     ;
526     my $v;
527    
528    
529     {
530    
531    
532     $v = $self->{
533     'b'
534     }->{${$self->{
535     'id'
536     }}}
537     ->{'con'};
538    
539    
540     }
541    
542     ;
543     $$v = defined $given ? $given : '';
544     ## NOTE: Setting NULL is supported for
545     ## compatibility with |textContent|.
546    
547    
548     }
549     }
550     }
551     sub base_uri ($;$) {
552     if (@_ == 1) {my ($self) = @_;
553 wakaba 1.8 my $r;
554 wakaba 1.1
555     {
556    
557    
558     {
559    
560     local $Error::Depth = $Error::Depth + 1;
561    
562     {
563    
564    
565     my
566     $pe = $self->
567     parent_node
568     ;
569     W: {
570     while (defined $pe) {
571     my $nt = $pe->
572     node_type
573     ;
574     if ($nt ==
575 wakaba 1.5 1 or
576 wakaba 1.1
577     $nt ==
578 wakaba 1.5 2 or
579 wakaba 1.1
580     $nt ==
581 wakaba 1.5 9 or
582 wakaba 1.1
583     $nt ==
584 wakaba 1.5 11 or
585 wakaba 1.1
586     $nt ==
587 wakaba 1.5 6
588 wakaba 1.1 ) {
589     $r = $pe->
590     base_uri
591     ;
592     last W;
593     } elsif ($nt ==
594 wakaba 1.5 5
595 wakaba 1.1 ) {
596     if ($pe->
597     manakai_external
598     ) {
599     $r = $pe->
600     manakai_entity_base_uri
601     ;
602     last W;
603     }
604     }
605     $pe = $pe->
606     parent_node
607     ;
608     }
609     if ($pe) {
610     $r = $pe->
611     base_uri
612     ;
613     } else {
614     $r = $self->
615     owner_document
616     ->
617     base_uri
618     ;
619     }
620     } # W
621    
622    
623    
624     }
625    
626    
627     ;}
628    
629     ;
630    
631    
632     }
633     $r;
634     } else {my ($self) = @_;
635     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'base_uri';
636     }
637     }
638     sub find_offset16 ($$) {
639     my ($self, $offset32) = @_;
640     my $r = 0;
641    
642     {
643    
644     my
645     $v;
646    
647    
648     {
649    
650    
651     $v = $self->{
652     'b'
653     }->{${$self->{
654     'id'
655     }}}
656     ->{'con'};
657    
658    
659     }
660    
661     ;
662    
663     if (not defined $offset32 or $offset32 < 0 or
664     CORE::length ($$v) < $offset32) {
665    
666     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#index' => $offset32, '-type' => 'INDEX_SIZE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'find_offset16', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#StringIndexOutOfBoundsException', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'offset32';
667    
668     ;
669     }
670    
671     my $ss = substr $$v, 0, $offset32;
672     $r = $offset32;
673     if ($ss =~ /[\x{10000}-\x{10FFFF}]/) {
674     while ($ss =~ /[\x{10000}-\x{10FFFF}]+/g) {
675     $r += $+[0] - $-[0];
676     }
677     }
678    
679    
680     }
681     $r}
682     sub find_offset32 ($$) {
683     my ($self, $offset16) = @_;
684     my $r = 0;
685    
686     {
687    
688     my
689     $v;
690    
691    
692     {
693    
694    
695     $v = $self->{
696     'b'
697     }->{${$self->{
698     'id'
699     }}}
700     ->{'con'};
701    
702    
703     }
704    
705     ;
706    
707     if (not defined $offset16 or $offset16 < 0) {
708    
709     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#index' => $offset16, '-type' => 'INDEX_SIZE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'find_offset32', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#StringIndexOutOfBoundsException', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'offset16';
710    
711     ;
712     }
713    
714     my $o = $offset16;
715     while ($o > 0) {
716     my $c = substr ($$v, $r, 1);
717     if (length $c) {
718     if ($c =~ /[\x{10000}-\x{10FFFF}]/) {
719     $o -= 2;
720     } else {
721     $o--;
722     }
723     $r++;
724     } else {
725    
726     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#index' => $offset16, '-type' => 'INDEX_SIZE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'find_offset32', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#StringIndexOutOfBoundsException', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'offset16';
727    
728     ;
729     }
730     }
731    
732    
733     }
734     $r}
735     sub data ($;$) {
736     if (@_ == 1) {my ($self) = @_;
737 wakaba 1.8 my $r;
738 wakaba 1.1
739     {
740    
741     my
742     $v;
743    
744    
745     {
746    
747    
748     $v = $self->{
749     'b'
750     }->{${$self->{
751     'id'
752     }}}
753     ->{'con'};
754    
755    
756     }
757    
758     ;
759     $r = $$v;
760    
761    
762     }
763     $r;
764     } else {my ($self, $given) = @_;
765    
766     {
767    
768    
769     {
770    
771     if
772     ($self->
773     manakai_read_only
774     ) {
775    
776     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
777    
778     ;
779     }
780    
781    
782     }
783    
784     ;
785     my $v;
786    
787    
788     {
789    
790    
791     $v = $self->{
792     'b'
793     }->{${$self->{
794     'id'
795     }}}
796     ->{'con'};
797    
798    
799     }
800    
801     ;
802     $$v = defined $given ? $given : '';
803     ## NOTE: Setting NULL is supported for
804     ## compatibility with |textContent|.
805    
806    
807     }
808     }
809     }
810     sub length ($;$) {
811     if (@_ == 1) {my ($self) = @_;
812     my $r = 0;
813    
814     {
815    
816     my
817 wakaba 1.2 $v;
818    
819    
820     {
821    
822    
823     $v = $self->{
824     'b'
825     }->{${$self->{
826     'id'
827     }}}
828     ->{'con'};
829    
830    
831     }
832    
833 wakaba 1.1 ;
834 wakaba 1.2 $r = CORE::length $$v;
835     $r++ while $$v =~ /[\x{10000}-\x{10FFFF}]/g;
836 wakaba 1.1
837    
838     }
839     $r;
840     } else {my ($self) = @_;
841     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'length';
842     }
843     }
844     sub substring_data ($$$) {
845     my ($self, $offset, $count) = @_;
846 wakaba 1.8 my $r;
847 wakaba 1.2
848     {
849    
850    
851     {
852    
853     if
854     ($self->
855     manakai_read_only
856     ) {
857    
858     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
859    
860     ;
861     }
862    
863    
864     }
865    
866     ;
867     if ($count < 0) {
868    
869     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'INDEX_SIZE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'substring_data', 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#length' => $count, 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#NEGATIVE_LENGTH_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'count';
870    
871     ;
872     }
873     my $eoffset32;
874    
875    
876     try {local $Error::Depth = $Error::Depth + 3;
877    
878    
879     $eoffset32 = $self->
880     find_offset32
881    
882     ($offset + $count);
883     } catch
884     Message::DOM::IFLatest::DOMException with
885     {
886     my $err = shift;
887     if ($err->subtype eq
888     'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#StringIndexOutOfBoundsException'
889     ) {
890     $eoffset32 = ($offset + $count) * 2;
891     } else {
892     $err->throw;
893     }
894     };
895    
896    
897     {
898    
899     local $Error::Depth = $Error::Depth + 1;
900    
901     {
902    
903    
904     my
905     $offset32 = $self->
906     find_offset32
907     ($offset);
908     my $data = $self->
909     data
910     ;
911     $r = substr ($data, $offset32, $eoffset32 - $offset32);
912    
913    
914    
915     }
916    
917    
918     ;}
919    
920     ;
921    
922    
923     }
924 wakaba 1.1 $r}
925     sub append_data ($$) {
926     my ($self, $arg) = @_;
927    
928     {
929    
930    
931     {
932    
933     local $Error::Depth = $Error::Depth + 1;
934    
935     {
936    
937    
938    
939     $self->
940     manakai_append_text
941     (\$arg);
942    
943    
944    
945     }
946    
947    
948     ;}
949    
950     ;
951    
952    
953     }
954     }
955     sub insert_data ($$$) {
956     my ($self, $offset, $arg) = @_;
957 wakaba 1.2
958     {
959    
960    
961     {
962    
963     if
964     ($self->
965     manakai_read_only
966     ) {
967    
968     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
969    
970     ;
971     }
972    
973    
974     }
975    
976     ;
977    
978    
979     {
980    
981     local $Error::Depth = $Error::Depth + 1;
982    
983     {
984    
985    
986     my
987     $offset32 = $self->
988     find_offset32
989     ($offset);
990     my $data = $self->
991     data
992     ;
993     substr ($data, $offset32, 0) = $arg;
994     $self->
995     data
996     ($data);
997    
998    
999    
1000     }
1001    
1002    
1003     ;}
1004    
1005     ;
1006    
1007    
1008     }
1009 wakaba 1.1 }
1010     sub delete_data ($$$) {
1011     my ($self, $offset, $count) = @_;
1012 wakaba 1.2
1013     {
1014    
1015    
1016     {
1017    
1018     if
1019     ($self->
1020     manakai_read_only
1021     ) {
1022    
1023     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
1024    
1025     ;
1026     }
1027    
1028    
1029     }
1030    
1031     ;
1032     if ($count < 0) {
1033    
1034     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'INDEX_SIZE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'delete_data', 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#length' => $count, 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#NEGATIVE_LENGTH_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMCharacterData', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#param-name' => 'count';
1035    
1036     ;
1037     }
1038     my $eoffset32;
1039    
1040    
1041     try {local $Error::Depth = $Error::Depth + 3;
1042    
1043    
1044     $eoffset32 = $self->
1045     find_offset32
1046    
1047     ($offset + $count);
1048     } catch
1049     Message::DOM::IFLatest::DOMException with
1050     {
1051     my $err = shift;
1052     if ($err->subtype eq
1053     'http://suika.fam.cx/~wakaba/archive/2004/8/18/dom-core#StringIndexOutOfBoundsException'
1054     ) {
1055     $eoffset32 = ($offset + $count) * 2;
1056     } else {
1057     $err->throw;
1058     }
1059     };
1060    
1061    
1062     {
1063    
1064     local $Error::Depth = $Error::Depth + 1;
1065    
1066     {
1067    
1068    
1069     my
1070     $offset32 = $self->
1071     find_offset32
1072     ($offset);
1073     my $data = $self->
1074     data
1075     ;
1076     substr ($data, $offset32, $eoffset32 - $offset32) = '';
1077     $self->
1078     data
1079     ($data);
1080    
1081    
1082    
1083     }
1084    
1085    
1086     ;}
1087    
1088     ;
1089    
1090    
1091     }
1092 wakaba 1.1 }
1093     sub replace_data ($$$$) {
1094     my ($self, $offset, $count, $arg) = @_;
1095    
1096 wakaba 1.2 {
1097    
1098    
1099     {
1100    
1101     local $Error::Depth = $Error::Depth + 1;
1102    
1103     {
1104    
1105    
1106    
1107     $self->
1108     delete_data
1109     ($offset, $count);
1110     $self->
1111     insert_data
1112     ($offset, $arg);
1113    
1114    
1115 wakaba 1.1
1116     }
1117 wakaba 1.2
1118    
1119     ;}
1120    
1121     ;
1122    
1123    
1124     }
1125     }
1126 wakaba 1.1 $Message::DOM::DOMFeature::ClassInfo->{q<Message::DOM::CharacterData::ManakaiDOMCharacterData>}->{has_feature} = {'core',
1127     {'',
1128     '1',
1129     '1.0',
1130     '1',
1131     '2.0',
1132     '1',
1133     '3.0',
1134     '1'},
1135     'xml',
1136     {'',
1137     '1',
1138     '1.0',
1139     '1',
1140     '2.0',
1141     '1',
1142     '3.0',
1143     '1'},
1144     'xmlversion',
1145     {'',
1146     '1',
1147     '1.0',
1148     '1',
1149     '1.1',
1150     '1'}};
1151     $Message::DOM::ClassPoint{q<Message::DOM::CharacterData::ManakaiDOMCharacterData>} = 14.1;
1152     $Message::Util::Grove::ClassProp{q<Message::DOM::CharacterData::ManakaiDOMCharacterData>} = {'o0',
1153     ['parent'],
1154     'w0',
1155     ['od']};
1156     package Message::DOM::IFLatest::Text;
1157 wakaba 1.8 our $VERSION = 20061202.0952;
1158 wakaba 1.1 package Message::DOM::CharacterData::ManakaiDOMText;
1159 wakaba 1.8 our $VERSION = 20061202.0952;
1160 wakaba 1.1 push our @ISA, 'Message::DOM::CharacterData::ManakaiDOMCharacterData',
1161     'Message::DOM::IF::CharacterData',
1162     'Message::DOM::IF::Node',
1163     'Message::DOM::IF::Text',
1164     'Message::DOM::IFLatest::CharacterData',
1165     'Message::DOM::IFLatest::Node',
1166     'Message::DOM::IFLatest::Text',
1167     'Message::DOM::IFLevel1::CharacterData',
1168     'Message::DOM::IFLevel1::Node',
1169     'Message::DOM::IFLevel1::Text',
1170     'Message::DOM::IFLevel2::CharacterData',
1171     'Message::DOM::IFLevel2::Node',
1172     'Message::DOM::IFLevel2::Text',
1173     'Message::DOM::IFLevel3::CharacterData',
1174     'Message::DOM::IFLevel3::Node',
1175     'Message::DOM::IFLevel3::Text';
1176     sub node_type ($;$) {
1177     if (@_ == 1) {my ($self) = @_;
1178     my $r;
1179 wakaba 1.5 $r = 3;
1180 wakaba 1.1 $r;
1181     } else {my ($self) = @_;
1182     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMText', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'node_type';
1183     }
1184     }
1185     sub node_name ($;$) {
1186     if (@_ == 1) {my ($self) = @_;
1187     my $r = '#text';
1188     $r;
1189     } else {my ($self) = @_;
1190     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMText', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'node_name';
1191     }
1192     }
1193     sub get_feature ($$$) {
1194     my ($self, $feature, $version) = @_;
1195    
1196     {
1197    
1198    
1199     $feature = lc $feature;
1200    
1201    
1202     }
1203    
1204     {
1205    
1206    
1207     $version = '' unless defined $version;
1208    
1209    
1210     }
1211     my $r;
1212    
1213     {
1214    
1215    
1216     $feature =~ s/^\+//;
1217    
1218    
1219     {
1220    
1221     if
1222 wakaba 1.7 ($Message::Util::AutoLoad::Registry::Feature->{$feature}->{$version}) {
1223 wakaba 1.1 $r = $self;
1224     }
1225    
1226    
1227     }
1228    
1229     ;
1230     unless (defined $r) {
1231    
1232    
1233     {
1234    
1235     local $Error::Depth = $Error::Depth + 1;
1236    
1237     {
1238    
1239    
1240    
1241     $r = $self->SUPER::get_feature ($feature, $version);
1242    
1243    
1244    
1245     }
1246    
1247    
1248     ;}
1249    
1250     ;
1251     }
1252    
1253    
1254     }
1255     $r}
1256     sub is_element_content_whitespace ($;$) {
1257     if (@_ == 1) {my ($self) = @_;
1258     my $r = 0;
1259    
1260     {
1261    
1262    
1263     {
1264    
1265    
1266     $r = $self->{
1267     'b'
1268     }->{${$self->{
1269     'id'
1270     }}}
1271     ->{'ecws'};
1272    
1273    
1274     }
1275    
1276     ;
1277    
1278    
1279     }
1280     $r;
1281     } else {my ($self, $given) = @_;
1282    
1283     {
1284    
1285    
1286     {
1287    
1288     if
1289     ($self->
1290     manakai_read_only
1291     ) {
1292    
1293     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
1294    
1295     ;
1296     }
1297    
1298    
1299     }
1300    
1301     ;
1302    
1303    
1304     {
1305    
1306    
1307     $self->{
1308     'b'
1309     }->{${$self->{
1310     'id'
1311     }}}
1312     ->{'ecws'} = $given;
1313    
1314    
1315     }
1316    
1317     ;
1318    
1319    
1320     }
1321     }
1322     }
1323     sub whole_text ($;$) {
1324     if (@_ == 1) {my ($self) = @_;
1325 wakaba 1.8 my $r;
1326 wakaba 1.3
1327     {
1328    
1329    
1330     {
1331    
1332     local $Error::Depth = $Error::Depth + 1;
1333    
1334     {
1335    
1336    
1337     require
1338     Message::DOM::Traversal;
1339     my $doc = $self->
1340     owner_document
1341     ;
1342     my $doctrv = $doc->
1343     get_feature
1344     (Traversal => '2.0');
1345     my $tw1 = $doctrv->
1346     create_tree_walker
1347    
1348     ($doc,
1349 wakaba 1.5 4294967295
1350 wakaba 1.3 , sub {
1351     ($_[1]->
1352     node_type
1353    
1354     ==
1355 wakaba 1.5 5
1356 wakaba 1.3 )
1357     ?
1358 wakaba 1.5 3
1359 wakaba 1.3 :
1360    
1361 wakaba 1.5 1
1362 wakaba 1.3
1363     },
1364     1
1365     );
1366     $tw1->
1367     current_node
1368     ($self);
1369     my $tw2 = $tw1->clone;
1370     $r = $self->
1371     node_value
1372     ;
1373    
1374     S: while (defined (my $node = $tw1->
1375     previous_sibling
1376     )) {
1377     my $nt = $node->
1378     node_type
1379     ;
1380     if ($nt ==
1381 wakaba 1.5 3 or
1382 wakaba 1.3
1383     $nt ==
1384 wakaba 1.5 4
1385 wakaba 1.3 ) {
1386     $r = $node->
1387     node_value
1388     . $r;
1389     } else {
1390     last S;
1391     }
1392     } # S
1393    
1394     S: while (defined (my $node = $tw2->
1395     next_sibling
1396     )) {
1397     my $nt = $node->
1398     node_type
1399     ;
1400     if ($nt ==
1401 wakaba 1.5 3 or
1402 wakaba 1.3
1403     $nt ==
1404 wakaba 1.5 4
1405 wakaba 1.3 ) {
1406     $r .= $node->
1407     node_value
1408     ;
1409     } else {
1410     last S;
1411     }
1412     } # S
1413    
1414    
1415    
1416     }
1417    
1418    
1419     ;}
1420    
1421     ;
1422    
1423    
1424     }
1425     $r;
1426 wakaba 1.1 } else {my ($self) = @_;
1427     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMText', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'whole_text';
1428     }
1429     }
1430     sub replace_whole_text ($$) {
1431     my ($self, $content) = @_;
1432     my $r;
1433     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NOT_SUPPORTED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'replace_whole_text', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#MDOM_IMPL_METHOD_NOT_IMPLEMENTED', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMText';
1434     $r}
1435     sub split_text ($$) {
1436     my ($self, $offset) = @_;
1437     my $r;
1438 wakaba 1.2
1439     {
1440    
1441    
1442     {
1443    
1444     if
1445     ($self->
1446     manakai_read_only
1447     ) {
1448    
1449     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_THIS', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#resourceURI' => 'tag:suika.fam.cx,2005-09:http://suika.fam.cx/~wakaba/archive/2005/manakai/DOM/TreeCore/NodeReadOnlyError+http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom%23ManakaiDOMLatest';
1450    
1451     ;
1452     }
1453    
1454    
1455     }
1456    
1457     ;
1458     my $parent = $self->
1459     parent_node
1460     ;
1461     if (defined $parent and $parent->
1462     manakai_read_only
1463     ) {
1464    
1465     report Message::DOM::DOMCore::ManakaiDOMException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#method' => 'split_text', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#NOMOD_PARENT', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMText';
1466    
1467     ;
1468     }
1469    
1470    
1471    
1472     {
1473    
1474     local $Error::Depth = $Error::Depth + 1;
1475    
1476     {
1477    
1478    
1479     my
1480     $offset32 = $self->
1481     find_offset32
1482     ($offset);
1483     my $data1 = $self->
1484     data
1485     ;
1486     my $data2 = substr ($data1, $offset32);
1487     substr ($data1, $offset32) = '';
1488    
1489     $r = $self->
1490     node_type
1491     ==
1492 wakaba 1.5 3
1493 wakaba 1.2
1494     ? $self->
1495     owner_document
1496    
1497     ->
1498     create_text_node
1499     ($data2)
1500     : $self->
1501     owner_document
1502    
1503     ->
1504     create_cdata_section
1505     ($data2);
1506     $r->
1507     is_element_content_whitespace
1508    
1509     ($self->
1510     is_element_content_whitespace
1511     );
1512     $self->
1513     data
1514     ($data1);
1515     if (defined $parent) {
1516     $parent->
1517     insert_before
1518    
1519     ($r, $self->
1520     next_sibling
1521     );
1522     }
1523    
1524    
1525    
1526     }
1527    
1528    
1529     ;}
1530    
1531     ;
1532    
1533    
1534     }
1535 wakaba 1.1 $r}
1536     $Message::DOM::DOMFeature::ClassInfo->{q<Message::DOM::CharacterData::ManakaiDOMText>}->{has_feature} = {'core',
1537     {'',
1538     '1',
1539     '1.0',
1540     '1',
1541     '2.0',
1542     '1',
1543     '3.0',
1544     '1'},
1545     'xml',
1546     {'',
1547     '1',
1548     '1.0',
1549     '1',
1550     '2.0',
1551     '1',
1552     '3.0',
1553     '1'},
1554     'xmlversion',
1555     {'',
1556     '1',
1557     '1.0',
1558     '1',
1559     '1.1',
1560     '1'}};
1561     $Message::DOM::ClassPoint{q<Message::DOM::CharacterData::ManakaiDOMText>} = 14.1;
1562     $Message::DOM::DOMFeature::ClassInfo->{q<Message::DOM::TreeCore::ManakaiDOMText>}->{compat_class}->{q<Message::DOM::CharacterData::ManakaiDOMText>} = 1;
1563     $Message::Util::Grove::ClassProp{q<Message::DOM::CharacterData::ManakaiDOMText>} = {'o0',
1564     ['parent'],
1565     'w0',
1566     ['od']};
1567     package Message::DOM::IFLatest::Comment;
1568 wakaba 1.8 our $VERSION = 20061202.0952;
1569 wakaba 1.1 package Message::DOM::CharacterData::ManakaiDOMComment;
1570 wakaba 1.8 our $VERSION = 20061202.0952;
1571 wakaba 1.1 push our @ISA, 'Message::DOM::CharacterData::ManakaiDOMCharacterData',
1572     'Message::DOM::IF::CharacterData',
1573     'Message::DOM::IF::Comment',
1574     'Message::DOM::IF::Node',
1575     'Message::DOM::IFLatest::CharacterData',
1576     'Message::DOM::IFLatest::Comment',
1577     'Message::DOM::IFLatest::Node',
1578     'Message::DOM::IFLevel1::CharacterData',
1579     'Message::DOM::IFLevel1::Comment',
1580     'Message::DOM::IFLevel1::Node',
1581     'Message::DOM::IFLevel2::CharacterData',
1582     'Message::DOM::IFLevel2::Comment',
1583     'Message::DOM::IFLevel2::Node',
1584     'Message::DOM::IFLevel3::CharacterData',
1585     'Message::DOM::IFLevel3::Comment',
1586     'Message::DOM::IFLevel3::Node';
1587     sub node_type ($;$) {
1588     if (@_ == 1) {my ($self) = @_;
1589     my $r;
1590 wakaba 1.5 $r = 8;
1591 wakaba 1.1 $r;
1592     } else {my ($self) = @_;
1593     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMComment', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'node_type';
1594     }
1595     }
1596     sub node_name ($;$) {
1597     if (@_ == 1) {my ($self) = @_;
1598 wakaba 1.8 my $r;
1599 wakaba 1.1 $r = '#comment';
1600     $r;
1601     } else {my ($self) = @_;
1602     report Message::Util::Error::DOMException::CoreException -object => $self, '-type' => 'NO_MODIFICATION_ALLOWED_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#on' => 'get', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#subtype' => 'http://suika.fam.cx/~wakaba/archive/2005/manakai/Util/Error/DOMException#READ_ONLY_ATTRIBUTE_ERR', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#class' => 'Message::DOM::CharacterData::ManakaiDOMComment', 'http://suika.fam.cx/~wakaba/archive/2004/8/4/manakai-dom-exception#attr' => 'node_name';
1603     }
1604     }
1605     sub get_feature ($$$) {
1606     my ($self, $feature, $version) = @_;
1607    
1608     {
1609    
1610    
1611     $feature = lc $feature;
1612    
1613    
1614     }
1615    
1616     {
1617    
1618    
1619     $version = '' unless defined $version;
1620    
1621    
1622     }
1623     my $r;
1624    
1625     {
1626    
1627    
1628     $feature =~ s/^\+//;
1629    
1630    
1631     {
1632    
1633     if
1634 wakaba 1.7 ($Message::Util::AutoLoad::Registry::Feature->{$feature}->{$version}) {
1635 wakaba 1.1 $r = $self;
1636     }
1637    
1638    
1639     }
1640    
1641     ;
1642     unless (defined $r) {
1643    
1644    
1645     {
1646    
1647     local $Error::Depth = $Error::Depth + 1;
1648    
1649     {
1650    
1651    
1652    
1653     $r = $self->SUPER::get_feature ($feature, $version);
1654    
1655    
1656    
1657     }
1658    
1659    
1660     ;}
1661    
1662     ;
1663     }
1664    
1665    
1666     }
1667     $r}
1668     $Message::DOM::DOMFeature::ClassInfo->{q<Message::DOM::CharacterData::ManakaiDOMComment>}->{has_feature} = {'core',
1669     {'',
1670     '1',
1671     '1.0',
1672     '1',
1673     '2.0',
1674     '1',
1675     '3.0',
1676     '1'},
1677     'xml',
1678     {'',
1679     '1',
1680     '1.0',
1681     '1',
1682     '2.0',
1683     '1',
1684     '3.0',
1685     '1'},
1686     'xmlversion',
1687     {'',
1688     '1',
1689     '1.0',
1690     '1',
1691     '1.1',
1692     '1'}};
1693     $Message::DOM::ClassPoint{q<Message::DOM::CharacterData::ManakaiDOMComment>} = 14.1;
1694     $Message::DOM::DOMFeature::ClassInfo->{q<Message::DOM::TreeCore::ManakaiDOMComment>}->{compat_class}->{q<Message::DOM::CharacterData::ManakaiDOMComment>} = 1;
1695     $Message::Util::Grove::ClassProp{q<Message::DOM::CharacterData::ManakaiDOMComment>} = {'o0',
1696     ['parent'],
1697     'w0',
1698     ['od']};
1699     package Message::DOM::IFLatest::StringExtended;
1700 wakaba 1.8 our $VERSION = 20061202.0952;
1701 wakaba 1.1 for ($Message::DOM::IF::CharacterData::, $Message::DOM::IF::Comment::, $Message::DOM::IF::Node::, $Message::DOM::IF::Text::, $Message::DOM::IFLatest::Node::, $Message::DOM::IFLevel1::CharacterData::, $Message::DOM::IFLevel1::Comment::, $Message::DOM::IFLevel1::Node::, $Message::DOM::IFLevel1::Text::, $Message::DOM::IFLevel2::CharacterData::, $Message::DOM::IFLevel2::Comment::, $Message::DOM::IFLevel2::Node::, $Message::DOM::IFLevel2::Text::, $Message::DOM::IFLevel3::CharacterData::, $Message::DOM::IFLevel3::Comment::, $Message::DOM::IFLevel3::Node::, $Message::DOM::IFLevel3::Text::){}
1702     ## License: <http://suika.fam.cx/~wakaba/archive/2004/8/18/license#Perl+MPL>
1703     1;

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24