KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > xml > utils > UnImplNode


1 /*
2  * Copyright 1999-2004 The Apache Software Foundation.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */

16 /*
17  * $Id: UnImplNode.java,v 1.10 2004/02/17 04:21:14 minchau Exp $
18  */

19 package org.apache.xml.utils;
20
21 import org.apache.xml.res.XMLErrorResources;
22 import org.apache.xml.res.XMLMessages;
23
24 import org.w3c.dom.Attr JavaDoc;
25 import org.w3c.dom.CDATASection JavaDoc;
26 import org.w3c.dom.Comment JavaDoc;
27 import org.w3c.dom.DOMException JavaDoc;
28 import org.w3c.dom.DOMImplementation JavaDoc;
29 import org.w3c.dom.Document JavaDoc;
30 import org.w3c.dom.DocumentFragment JavaDoc;
31 import org.w3c.dom.DocumentType JavaDoc;
32 import org.w3c.dom.Element JavaDoc;
33 import org.w3c.dom.EntityReference JavaDoc;
34 import org.w3c.dom.NamedNodeMap JavaDoc;
35 import org.w3c.dom.Node JavaDoc;
36 import org.w3c.dom.NodeList JavaDoc;
37 import org.w3c.dom.ProcessingInstruction JavaDoc;
38 import org.w3c.dom.Text JavaDoc;
39
40 /**
41  * To be subclassed by classes that wish to fake being nodes.
42  * @xsl.usage internal
43  */

44 public class UnImplNode implements Node JavaDoc, Element JavaDoc, NodeList JavaDoc, Document JavaDoc
45 {
46
47   /**
48    * Constructor UnImplNode
49    *
50    */

51   public UnImplNode(){}
52
53   /**
54    * Throw an error.
55    *
56    * @param msg Message Key for the error
57    */

58   public void error(String JavaDoc msg)
59   {
60
61     System.out.println("DOM ERROR! class: " + this.getClass().getName());
62
63     throw new RuntimeException JavaDoc(XMLMessages.createXMLMessage(msg, null));
64   }
65
66   /**
67    * Throw an error.
68    *
69    * @param msg Message Key for the error
70    * @param args Array of arguments to be used in the error message
71    */

72   public void error(String JavaDoc msg, Object JavaDoc[] args)
73   {
74
75     System.out.println("DOM ERROR! class: " + this.getClass().getName());
76
77     throw new RuntimeException JavaDoc(XMLMessages.createXMLMessage(msg, args)); //"UnImplNode error: "+msg);
78
}
79
80   /**
81    * Unimplemented. See org.w3c.dom.Node
82    *
83    * @param newChild New node to append to the list of this node's children
84    *
85    * @return null
86    *
87    * @throws DOMException
88    */

89   public Node JavaDoc appendChild(Node JavaDoc newChild) throws DOMException JavaDoc
90   {
91
92     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"appendChild not supported!");
93

94     return null;
95   }
96
97   /**
98    * Unimplemented. See org.w3c.dom.Node
99    *
100    * @return false
101    */

102   public boolean hasChildNodes()
103   {
104
105     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"hasChildNodes not supported!");
106

107     return false;
108   }
109
110   /**
111    * Unimplemented. See org.w3c.dom.Node
112    *
113    * @return 0
114    */

115   public short getNodeType()
116   {
117
118     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getNodeType not supported!");
119

120     return 0;
121   }
122
123   /**
124    * Unimplemented. See org.w3c.dom.Node
125    *
126    * @return null
127    */

128   public Node JavaDoc getParentNode()
129   {
130
131     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getParentNode not supported!");
132

133     return null;
134   }
135
136   /**
137    * Unimplemented. See org.w3c.dom.Node
138    *
139    * @return null
140    */

141   public NodeList JavaDoc getChildNodes()
142   {
143
144     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getChildNodes not supported!");
145

146     return null;
147   }
148
149   /**
150    * Unimplemented. See org.w3c.dom.Node
151    *
152    * @return null
153    */

154   public Node JavaDoc getFirstChild()
155   {
156
157     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getFirstChild not supported!");
158

159     return null;
160   }
161
162   /**
163    * Unimplemented. See org.w3c.dom.Node
164    *
165    * @return null
166    */

167   public Node JavaDoc getLastChild()
168   {
169
170     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getLastChild not supported!");
171

172     return null;
173   }
174
175   /**
176    * Unimplemented. See org.w3c.dom.Node
177    *
178    * @return null
179    */

180   public Node JavaDoc getNextSibling()
181   {
182
183     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getNextSibling not supported!");
184

185     return null;
186   }
187
188   /**
189    * Unimplemented. See org.w3c.dom.NodeList
190    *
191    * @return 0
192    */

193   public int getLength()
194   {
195
196     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getLength not supported!");
197

198     return 0;
199   } // getLength():int
200

201   /**
202    * Unimplemented. See org.w3c.dom.NodeList
203    *
204    * @param index index of a child of this node in its list of children
205    *
206    * @return null
207    */

208   public Node JavaDoc item(int index)
209   {
210
211     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"item not supported!");
212

213     return null;
214   } // item(int):Node
215

216   /**
217    * Unimplemented. See org.w3c.dom.Node
218    *
219    * @return null
220    */

221   public Document JavaDoc getOwnerDocument()
222   {
223
224     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getOwnerDocument not supported!");
225

226     return null;
227   }
228
229   /**
230    * Unimplemented. See org.w3c.dom.Node
231    *
232    * @return null
233    */

234   public String JavaDoc getTagName()
235   {
236
237     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getTagName not supported!");
238

239     return null;
240   }
241
242   /**
243    * Unimplemented. See org.w3c.dom.Node
244    *
245    * @return null
246    */

247   public String JavaDoc getNodeName()
248   {
249
250     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getNodeName not supported!");
251

252     return null;
253   }
254
255   /** Unimplemented. See org.w3c.dom.Node */
256   public void normalize()
257   {
258     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"normalize not supported!");
259
}
260
261   /**
262    * Unimplemented. See org.w3c.dom.Element
263    *
264    * @param name Name of the element
265    *
266    * @return null
267    */

268   public NodeList JavaDoc getElementsByTagName(String JavaDoc name)
269   {
270
271     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getElementsByTagName not supported!");
272

273     return null;
274   }
275
276   /**
277    * Unimplemented. See org.w3c.dom.Element
278    *
279    * @param oldAttr Attribute to be removed from this node's list of attributes
280    *
281    * @return null
282    *
283    * @throws DOMException
284    */

285   public Attr JavaDoc removeAttributeNode(Attr JavaDoc oldAttr) throws DOMException JavaDoc
286   {
287
288     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"removeAttributeNode not supported!");
289

290     return null;
291   }
292
293   /**
294    * Unimplemented. See org.w3c.dom.Element
295    *
296    * @param newAttr Attribute node to be added to this node's list of attributes
297    *
298    * @return null
299    *
300    * @throws DOMException
301    */

302   public Attr JavaDoc setAttributeNode(Attr JavaDoc newAttr) throws DOMException JavaDoc
303   {
304
305     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setAttributeNode not supported!");
306

307     return null;
308   }
309
310   /**
311    * Unimplemented. See org.w3c.dom.Element
312    *
313    *
314    * @param name Name of an attribute
315    *
316    * @return false
317    */

318   public boolean hasAttribute(String JavaDoc name)
319   {
320
321     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"hasAttribute not supported!");
322

323     return false;
324   }
325
326   /**
327    * Unimplemented. See org.w3c.dom.Element
328    *
329    *
330    * @param name
331    * @param x
332    *
333    * @return false
334    */

335   public boolean hasAttributeNS(String JavaDoc name, String JavaDoc x)
336   {
337
338     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"hasAttributeNS not supported!");
339

340     return false;
341   }
342
343   /**
344    * Unimplemented. See org.w3c.dom.Element
345    *
346    *
347    * @param name Attribute node name
348    *
349    * @return null
350    */

351   public Attr JavaDoc getAttributeNode(String JavaDoc name)
352   {
353
354     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getAttributeNode not supported!");
355

356     return null;
357   }
358
359   /**
360    * Unimplemented. See org.w3c.dom.Element
361    *
362    * @param name Attribute node name to remove from list of attributes
363    *
364    * @throws DOMException
365    */

366   public void removeAttribute(String JavaDoc name) throws DOMException JavaDoc
367   {
368     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"removeAttribute not supported!");
369
}
370
371   /**
372    * Unimplemented. See org.w3c.dom.Element
373    *
374    * @param name Name of attribute to set
375    * @param value Value of attribute
376    *
377    * @throws DOMException
378    */

379   public void setAttribute(String JavaDoc name, String JavaDoc value) throws DOMException JavaDoc
380   {
381     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setAttribute not supported!");
382
}
383
384   /**
385    * Unimplemented. See org.w3c.dom.Element
386    *
387    * @param name Name of attribute to get
388    *
389    * @return null
390    */

391   public String JavaDoc getAttribute(String JavaDoc name)
392   {
393
394     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getAttribute not supported!");
395

396     return null;
397   }
398
399   /**
400    * Unimplemented. Introduced in DOM Level 2.
401    *
402    * @return false
403    */

404   public boolean hasAttributes()
405   {
406
407     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"hasAttributes not supported!");
408

409     return false;
410   }
411
412   /**
413    * Unimplemented. See org.w3c.dom.Element
414    *
415    * @param namespaceURI Namespace URI of the element
416    * @param localName Local part of qualified name of the element
417    *
418    * @return null
419    */

420   public NodeList JavaDoc getElementsByTagNameNS(String JavaDoc namespaceURI,
421                                          String JavaDoc localName)
422   {
423
424     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getElementsByTagNameNS not supported!");
425

426     return null;
427   }
428
429   /**
430    * Unimplemented. See org.w3c.dom.Element
431    *
432    * @param newAttr Attribute to set
433    *
434    * @return null
435    *
436    * @throws DOMException
437    */

438   public Attr JavaDoc setAttributeNodeNS(Attr JavaDoc newAttr) throws DOMException JavaDoc
439   {
440
441     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setAttributeNodeNS not supported!");
442

443     return null;
444   }
445
446   /**
447    * Unimplemented. See org.w3c.dom.Element
448    *
449    * @param namespaceURI Namespace URI of attribute node to get
450    * @param localName Local part of qualified name of attribute node to get
451    *
452    * @return null
453    */

454   public Attr JavaDoc getAttributeNodeNS(String JavaDoc namespaceURI, String JavaDoc localName)
455   {
456
457     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getAttributeNodeNS not supported!");
458

459     return null;
460   }
461
462   /**
463    * Unimplemented. See org.w3c.dom.Element
464    *
465    * @param namespaceURI Namespace URI of attribute node to remove
466    * @param localName Local part of qualified name of attribute node to remove
467    *
468    * @throws DOMException
469    */

470   public void removeAttributeNS(String JavaDoc namespaceURI, String JavaDoc localName)
471           throws DOMException JavaDoc
472   {
473     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"removeAttributeNS not supported!");
474
}
475
476   /**
477    * Unimplemented. See org.w3c.dom.Element
478    *
479    * @param namespaceURI Namespace URI of attribute node to set
480    * @param localName Local part of qualified name of attribute node to set
481    * NEEDSDOC @param qualifiedName
482    * @param value value of attribute
483    *
484    * @throws DOMException
485    */

486   public void setAttributeNS(
487           String JavaDoc namespaceURI, String JavaDoc qualifiedName, String JavaDoc value)
488             throws DOMException JavaDoc
489   {
490     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setAttributeNS not supported!");
491
}
492
493   /**
494    * Unimplemented. See org.w3c.dom.Element
495    *
496    * @param namespaceURI Namespace URI of attribute node to get
497    * @param localName Local part of qualified name of attribute node to get
498    *
499    * @return null
500    */

501   public String JavaDoc getAttributeNS(String JavaDoc namespaceURI, String JavaDoc localName)
502   {
503
504     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getAttributeNS not supported!");
505

506     return null;
507   }
508
509   /**
510    * Unimplemented. See org.w3c.dom.Node
511    *
512    * @return null
513    */

514   public Node JavaDoc getPreviousSibling()
515   {
516
517     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getPreviousSibling not supported!");
518

519     return null;
520   }
521
522   /**
523    * Unimplemented. See org.w3c.dom.Node
524    *
525    * @param deep Flag indicating whether to clone deep (clone member variables)
526    *
527    * @return null
528    */

529   public Node JavaDoc cloneNode(boolean deep)
530   {
531
532     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"cloneNode not supported!");
533

534     return null;
535   }
536
537   /**
538    * Unimplemented. See org.w3c.dom.Node
539    *
540    * @return null
541    *
542    * @throws DOMException
543    */

544   public String JavaDoc getNodeValue() throws DOMException JavaDoc
545   {
546
547     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getNodeValue not supported!");
548

549     return null;
550   }
551
552   /**
553    * Unimplemented. See org.w3c.dom.Node
554    *
555    * @param nodeValue Value to set this node to
556    *
557    * @throws DOMException
558    */

559   public void setNodeValue(String JavaDoc nodeValue) throws DOMException JavaDoc
560   {
561     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setNodeValue not supported!");
562
}
563
564   /**
565    * Unimplemented. See org.w3c.dom.Node
566    *
567    *
568    * NEEDSDOC @param value
569    * @return value Node value
570    *
571    * @throws DOMException
572    */

573
574   // public String getValue ()
575
// {
576
// error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getValue not supported!");
577
// return null;
578
// }
579

580   /**
581    * Unimplemented. See org.w3c.dom.Node
582    *
583    * @param value Value to set this node to
584    *
585    * @throws DOMException
586    */

587   public void setValue(String JavaDoc value) throws DOMException JavaDoc
588   {
589     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setValue not supported!");
590
}
591
592   /**
593    * Returns the name of this attribute.
594    *
595    * @return the name of this attribute.
596    */

597
598   // public String getName()
599
// {
600
// return this.getNodeName();
601
// }
602

603   /**
604    * Unimplemented. See org.w3c.dom.Node
605    *
606    * @return null
607    */

608   public Element JavaDoc getOwnerElement()
609   {
610
611     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getOwnerElement not supported!");
612

613     return null;
614   }
615
616   /**
617    * Unimplemented. See org.w3c.dom.Node
618    *
619    * @return False
620    */

621   public boolean getSpecified()
622   {
623
624     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setValue not supported!");
625

626     return false;
627   }
628
629   /**
630    * Unimplemented. See org.w3c.dom.Node
631    *
632    * @return null
633    */

634   public NamedNodeMap JavaDoc getAttributes()
635   {
636
637     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getAttributes not supported!");
638

639     return null;
640   }
641
642   /**
643    * Unimplemented. See org.w3c.dom.Node
644    *
645    * @param newChild New child node to insert
646    * @param refChild Insert in front of this child
647    *
648    * @return null
649    *
650    * @throws DOMException
651    */

652   public Node JavaDoc insertBefore(Node JavaDoc newChild, Node JavaDoc refChild) throws DOMException JavaDoc
653   {
654
655     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"insertBefore not supported!");
656

657     return null;
658   }
659
660   /**
661    * Unimplemented. See org.w3c.dom.Node
662    *
663    * @param newChild Replace existing child with this one
664    * @param oldChild Existing child to be replaced
665    *
666    * @return null
667    *
668    * @throws DOMException
669    */

670   public Node JavaDoc replaceChild(Node JavaDoc newChild, Node JavaDoc oldChild) throws DOMException JavaDoc
671   {
672
673     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"replaceChild not supported!");
674

675     return null;
676   }
677
678   /**
679    * Unimplemented. See org.w3c.dom.Node
680    *
681    * @param oldChild Child to be removed
682    *
683    * @return null
684    *
685    * @throws DOMException
686    */

687   public Node JavaDoc removeChild(Node JavaDoc oldChild) throws DOMException JavaDoc
688   {
689
690     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"replaceChild not supported!");
691

692     return null;
693   }
694
695   /**
696    * Tests whether the DOM implementation implements a specific feature and
697    * that feature is supported by this node.
698    * @param featureThe name of the feature to test. This is the same name
699    * which can be passed to the method <code>hasFeature</code> on
700    * <code>DOMImplementation</code>.
701    * @param versionThis is the version number of the feature to test. In
702    * Level 2, version 1, this is the string "2.0". If the version is not
703    * specified, supporting any version of the feature will cause the
704    * method to return <code>true</code>.
705    *
706    * NEEDSDOC @param feature
707    * NEEDSDOC @param version
708    * @return Returns <code>false</code>
709    * @since DOM Level 2
710    */

711   public boolean isSupported(String JavaDoc feature, String JavaDoc version)
712   {
713     return false;
714   }
715
716   /**
717    * Unimplemented. See org.w3c.dom.Node
718    *
719    * @return null
720    */

721   public String JavaDoc getNamespaceURI()
722   {
723
724     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getNamespaceURI not supported!");
725

726     return null;
727   }
728
729   /**
730    * Unimplemented. See org.w3c.dom.Node
731    *
732    * @return null
733    */

734   public String JavaDoc getPrefix()
735   {
736
737     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getPrefix not supported!");
738

739     return null;
740   }
741
742   /**
743    * Unimplemented. See org.w3c.dom.Node
744    *
745    * @param prefix Prefix to set for this node
746    *
747    * @throws DOMException
748    */

749   public void setPrefix(String JavaDoc prefix) throws DOMException JavaDoc
750   {
751     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"setPrefix not supported!");
752
}
753
754   /**
755    * Unimplemented. See org.w3c.dom.Node
756    *
757    * @return null
758    */

759   public String JavaDoc getLocalName()
760   {
761
762     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED); //"getLocalName not supported!");
763

764     return null;
765   }
766
767   /**
768    * Unimplemented. See org.w3c.dom.Document
769    *
770    * @return null
771    */

772   public DocumentType JavaDoc getDoctype()
773   {
774
775     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
776
777     return null;
778   }
779
780   /**
781    * Unimplemented. See org.w3c.dom.Document
782    *
783    * @return null
784    */

785   public DOMImplementation JavaDoc getImplementation()
786   {
787
788     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
789
790     return null;
791   }
792
793   /**
794    * Unimplemented. See org.w3c.dom.Document
795    *
796    * @return null
797    */

798   public Element JavaDoc getDocumentElement()
799   {
800
801     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
802
803     return null;
804   }
805
806   /**
807    * Unimplemented. See org.w3c.dom.Document
808    *
809    * @param tagName Element tag name
810    *
811    * @return null
812    *
813    * @throws DOMException
814    */

815   public Element JavaDoc createElement(String JavaDoc tagName) throws DOMException JavaDoc
816   {
817
818     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
819
820     return null;
821   }
822
823   /**
824    * Unimplemented. See org.w3c.dom.Document
825    *
826    * @return null
827    */

828   public DocumentFragment JavaDoc createDocumentFragment()
829   {
830
831     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
832
833     return null;
834   }
835
836   /**
837    * Unimplemented. See org.w3c.dom.Document
838    *
839    * @param data Data for text node
840    *
841    * @return null
842    */

843   public Text JavaDoc createTextNode(String JavaDoc data)
844   {
845
846     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
847
848     return null;
849   }
850
851   /**
852    * Unimplemented. See org.w3c.dom.Document
853    *
854    * @param data Data for comment
855    *
856    * @return null
857    */

858   public Comment JavaDoc createComment(String JavaDoc data)
859   {
860
861     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
862
863     return null;
864   }
865
866   /**
867    * Unimplemented. See org.w3c.dom.Document
868    *
869    * @param data Data for CDATA section
870    *
871    * @return null
872    *
873    * @throws DOMException
874    */

875   public CDATASection JavaDoc createCDATASection(String JavaDoc data) throws DOMException JavaDoc
876   {
877
878     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
879
880     return null;
881   }
882
883   /**
884    * Unimplemented. See org.w3c.dom.Document
885    *
886    * @param target Target for Processing instruction
887    * @param data Data for Processing instruction
888    *
889    * @return null
890    *
891    * @throws DOMException
892    */

893   public ProcessingInstruction JavaDoc createProcessingInstruction(
894           String JavaDoc target, String JavaDoc data) throws DOMException JavaDoc
895   {
896
897     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
898
899     return null;
900   }
901
902   /**
903    * Unimplemented. See org.w3c.dom.Document
904    *
905    * @param name Attribute name
906    *
907    * @return null
908    *
909    * @throws DOMException
910    */

911   public Attr JavaDoc createAttribute(String JavaDoc name) throws DOMException JavaDoc
912   {
913
914     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
915
916     return null;
917   }
918
919   /**
920    * Unimplemented. See org.w3c.dom.Document
921    *
922    * @param name Entity Reference name
923    *
924    * @return null
925    *
926    * @throws DOMException
927    */

928   public EntityReference JavaDoc createEntityReference(String JavaDoc name)
929           throws DOMException JavaDoc
930   {
931
932     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
933
934     return null;
935   }
936
937   /**
938    * Unimplemented. See org.w3c.dom.Document
939    *
940    * @param importedNodeThe node to import.
941    * @param deepIf <code>true</code>, recursively import the subtree under
942    * the specified node; if <code>false</code>, import only the node
943    * itself, as explained above. This has no effect on <code>Attr</code>
944    * , <code>EntityReference</code>, and <code>Notation</code> nodes.
945    *
946    * NEEDSDOC @param importedNode
947    * NEEDSDOC @param deep
948    *
949    * @return null
950    *
951    * @throws DOMException
952    */

953   public Node JavaDoc importNode(Node JavaDoc importedNode, boolean deep) throws DOMException JavaDoc
954   {
955
956     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
957
958     return null;
959   }
960
961   /**
962    * Unimplemented. See org.w3c.dom.Document
963    *
964    * @param namespaceURI Namespace URI for the element
965    * @param qualifiedName Qualified name of the element
966    *
967    * @return null
968    *
969    * @throws DOMException
970    */

971   public Element JavaDoc createElementNS(String JavaDoc namespaceURI, String JavaDoc qualifiedName)
972           throws DOMException JavaDoc
973   {
974
975     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
976
977     return null;
978   }
979
980   /**
981    * Unimplemented. See org.w3c.dom.Document
982    *
983    * @param namespaceURI Namespace URI of the attribute
984    * @param qualifiedName Qualified name of the attribute
985    *
986    * @return null
987    *
988    * @throws DOMException
989    */

990   public Attr JavaDoc createAttributeNS(String JavaDoc namespaceURI, String JavaDoc qualifiedName)
991           throws DOMException JavaDoc
992   {
993
994     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
995
996     return null;
997   }
998
999   /**
1000   * Unimplemented. See org.w3c.dom.Document
1001   *
1002   * @param elementId ID of the element to get
1003   *
1004   * @return null
1005   */

1006  public Element JavaDoc getElementById(String JavaDoc elementId)
1007  {
1008
1009    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1010
1011    return null;
1012  }
1013
1014  /**
1015   * Set Node data
1016   *
1017   *
1018   * @param data data to set for this node
1019   *
1020   * @throws DOMException
1021   */

1022  public void setData(String JavaDoc data) throws DOMException JavaDoc
1023  {
1024    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1025  }
1026
1027  /**
1028   * Unimplemented.
1029   *
1030   * @param offset Start offset of substring to extract.
1031   * @param count The length of the substring to extract.
1032   *
1033   * @return null
1034   *
1035   * @throws DOMException
1036   */

1037  public String JavaDoc substringData(int offset, int count) throws DOMException JavaDoc
1038  {
1039
1040    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1041
1042    return null;
1043  }
1044
1045  /**
1046   * Unimplemented.
1047   *
1048   * @param arg String data to append
1049   *
1050   * @throws DOMException
1051   */

1052  public void appendData(String JavaDoc arg) throws DOMException JavaDoc
1053  {
1054    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1055  }
1056
1057  /**
1058   * Unimplemented.
1059   *
1060   * @param offset Start offset of substring to insert.
1061   * @param count The length of the substring to insert.
1062   * NEEDSDOC @param arg
1063   *
1064   * @throws DOMException
1065   */

1066  public void insertData(int offset, String JavaDoc arg) throws DOMException JavaDoc
1067  {
1068    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1069  }
1070
1071  /**
1072   * Unimplemented.
1073   *
1074   * @param offset Start offset of substring to delete.
1075   * @param count The length of the substring to delete.
1076   *
1077   * @throws DOMException
1078   */

1079  public void deleteData(int offset, int count) throws DOMException JavaDoc
1080  {
1081    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1082  }
1083
1084  /**
1085   * Unimplemented.
1086   *
1087   * @param offset Start offset of substring to replace.
1088   * @param count The length of the substring to replace.
1089   * @param arg substring to replace with
1090   *
1091   * @throws DOMException
1092   */

1093  public void replaceData(int offset, int count, String JavaDoc arg)
1094          throws DOMException JavaDoc
1095  {
1096    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1097  }
1098
1099  /**
1100   * Unimplemented.
1101   *
1102   * @param offset Offset into text to split
1103   *
1104   * @return null, unimplemented
1105   *
1106   * @throws DOMException
1107   */

1108  public Text JavaDoc splitText(int offset) throws DOMException JavaDoc
1109  {
1110
1111    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1112
1113    return null;
1114  }
1115
1116  /**
1117   * NEEDSDOC Method adoptNode
1118   *
1119   *
1120   * NEEDSDOC @param source
1121   *
1122   * NEEDSDOC (adoptNode) @return
1123   *
1124   * @throws DOMException
1125   */

1126  public Node JavaDoc adoptNode(Node JavaDoc source) throws DOMException JavaDoc
1127  {
1128
1129    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1130
1131    return null;
1132  }
1133
1134  /**
1135   * <p>EXPERIMENTAL! Based on the <a
1136   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1137   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1138   * <p>
1139   * An attribute specifying, as part of the XML declaration, the encoding
1140   * of this document. This is <code>null</code> when unspecified.
1141   * @since DOM Level 3
1142   *
1143   * NEEDSDOC ($objectName$) @return
1144   */

1145  public String JavaDoc getEncoding()
1146  {
1147
1148    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1149
1150    return null;
1151  }
1152
1153  /**
1154   * <p>EXPERIMENTAL! Based on the <a
1155   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1156   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1157   * <p>
1158   * An attribute specifying, as part of the XML declaration, the encoding
1159   * of this document. This is <code>null</code> when unspecified.
1160   * @since DOM Level 3
1161   *
1162   * NEEDSDOC @param encoding
1163   */

1164  public void setEncoding(String JavaDoc encoding)
1165  {
1166    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1167  }
1168
1169  /**
1170   * <p>EXPERIMENTAL! Based on the <a
1171   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1172   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1173   * <p>
1174   * An attribute specifying, as part of the XML declaration, whether this
1175   * document is standalone.
1176   * @since DOM Level 3
1177   *
1178   * NEEDSDOC ($objectName$) @return
1179   */

1180  public boolean getStandalone()
1181  {
1182
1183    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1184
1185    return false;
1186  }
1187
1188  /**
1189   * <p>EXPERIMENTAL! Based on the <a
1190   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1191   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1192   * <p>
1193   * An attribute specifying, as part of the XML declaration, whether this
1194   * document is standalone.
1195   * @since DOM Level 3
1196   *
1197   * NEEDSDOC @param standalone
1198   */

1199  public void setStandalone(boolean standalone)
1200  {
1201    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1202  }
1203
1204  /**
1205   * <p>EXPERIMENTAL! Based on the <a
1206   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1207   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1208   * <p>
1209   * An attribute specifying whether errors checking is enforced or not.
1210   * When set to <code>false</code>, the implementation is free to not
1211   * test every possible error case normally defined on DOM operations,
1212   * and not raise any <code>DOMException</code>. In case of error, the
1213   * behavior is undefined. This attribute is <code>true</code> by
1214   * defaults.
1215   * @since DOM Level 3
1216   *
1217   * NEEDSDOC ($objectName$) @return
1218   */

1219  public boolean getStrictErrorChecking()
1220  {
1221
1222    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1223
1224    return false;
1225  }
1226
1227  /**
1228   * <p>EXPERIMENTAL! Based on the <a
1229   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1230   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1231   * <p>
1232   * An attribute specifying whether errors checking is enforced or not.
1233   * When set to <code>false</code>, the implementation is free to not
1234   * test every possible error case normally defined on DOM operations,
1235   * and not raise any <code>DOMException</code>. In case of error, the
1236   * behavior is undefined. This attribute is <code>true</code> by
1237   * defaults.
1238   * @since DOM Level 3
1239   *
1240   * NEEDSDOC @param strictErrorChecking
1241   */

1242  public void setStrictErrorChecking(boolean strictErrorChecking)
1243  {
1244    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1245  }
1246
1247  /**
1248   * <p>EXPERIMENTAL! Based on the <a
1249   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1250   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1251   * <p>
1252   * An attribute specifying, as part of the XML declaration, the version
1253   * number of this document. This is <code>null</code> when unspecified.
1254   * @since DOM Level 3
1255   *
1256   * NEEDSDOC ($objectName$) @return
1257   */

1258  public String JavaDoc getVersion()
1259  {
1260
1261    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1262
1263    return null;
1264  }
1265
1266  /**
1267   * <p>EXPERIMENTAL! Based on the <a
1268   * HREF='http://www.w3.org/TR/2001/WD-DOM-Level-3-Core-20010605'>Document
1269   * Object Model (DOM) Level 3 Core Working Draft of 5 June 2001.</a>.
1270   * <p>
1271   * An attribute specifying, as part of the XML declaration, the version
1272   * number of this document. This is <code>null</code> when unspecified.
1273   * @since DOM Level 3
1274   *
1275   * NEEDSDOC @param version
1276   */

1277  public void setVersion(String JavaDoc version)
1278  {
1279    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
1280  }
1281}
1282
Popular Tags