Re: java.lang.ClassCastException: org.apache.xerces.dom.ElementNSImpl

2005-02-21 Thread Michael Glavassevich
Perhaps I'm missing something but it seems you've extended Node but not ElementNSImpl to implement this new interface. You'd also have to return an instance of the subclass from Document.createElementNS(). If you haven't done that then the ClassCastException should be expected since the element

XInclude and schemas

2005-02-21 Thread Dean, Tim (STP)
Hi, I'm trying to do some experiments using XInclude. My XML files are validated using XML schema (not DTD's). When I try to validate my document, the parser reports "Document is invalid: no grammar found" once it starts parsing the included document. I've searched the mailing list archives, a

java.lang.ClassCastException: org.apache.xerces.dom.ElementNSImpl

2005-02-21 Thread jx...@tiscali.fr
Hello, I got a strange exception. Here is my problem : public interface SecureDocument extends Node { } public class SecDocImpl extends DocumentImpl { public static void main(String[] args) { try { InputStrea

RE : Serialisation with no default namespace prefix

2005-02-21 Thread Stéphane Rault
Do you have a snippet of the code that constructs the elements? I believe you just need to create the namespace attribute declaration correctly. In your example you have 'xmlns:ced="namespace"', but what you want is 'xmlns="namespace"', but that could just be a typo. Ymailto:[EMAIL PROTECTED] S

RE: Serialisation with no default namespace prefix

2005-02-21 Thread Nathan Beyer
Do you have a snippet of the code that constructs the elements? I believe you just need to create the namespace attribute declaration correctly. In your example you have 'xmlns:ced="namespace"', but what you want is 'xmlns="namespace"', but that could just be a typo. -Original Message- Fr

Serialisation with no default namespace prefix

2005-02-21 Thread Stéphane Rault
Hello all. I want to serialize some Xml Documents with namespace inside but with a defaultNamespace and no prefix for this namespace. How can I do it ? // Piece of code OutputFormat format = new OutputFormat("xml", "ISO-8859-1", true); XMLSerializer serialiseur = new XML

Re: xpath

2005-02-21 Thread Robert van Loenhout
Robert van Loenhout wrote: Phil Weighill-Smith wrote: In this case, why not use: ...(root, "child::[EMAIL PROTECTED]'\"value'/@name"); Because the xpath is created dynamically. And even though a " quote can be detected first, it still does not help if both a " and a ' is contained in the value. Ok