[jdom-interest] Bug??

Jason Hunter jhunter at collab.net
Fri Apr 20 13:48:25 PDT 2001


Try the latest code in CVS.  This is already fixed.

-jh-

Per Kreipke wrote:
> 
> Using JDOM 1.0b6,
> 
> On line 403 of DOMBuilder.java, in the processing of DOM Elements, the name
> for the new JDOM Element is taken from the localname of the DOM Element.
> However, according to the language of the DOM Core Level 2 (under the Node
> section):
> 
> "localName of type DOMString, readonly, introduced in DOM Level 2
> 
> Returns the local part of the qualified name of this node.
> For nodes of any type other than ELEMENT_NODE and ATTRIBUTE_NODE and nodes
> created with a DOM Level 1 method, such as createElement from the Document
> interface, this is always null."
> 
> The emphasis in my case is on 'nodes created with a DOM Level 1 method'. I'm
> using Xerces 1.3.1 and Xalan 1.2.2 and when I transform my input document
> and then try to transform it to JDOM, I get an error:
> 
> org.jdom.IllegalNameException: The name "null" is not legal for JDOM/XML
> elements: XML names cannot be null or empty.
>         at org.jdom.Element.<init>(Element.java:137)
>         at org.jdom.Element.<init>(Element.java:160)
>         at org.jdom.input.DOMBuilder.buildTree(DOMBuilder.java:409)
>         at org.jdom.input.DOMBuilder.build(DOMBuilder.java:373)
>         ...
> 
> Comments?
> 
> Per.
> 
> _______________________________________________
> To control your jdom-interest membership:
> http://lists.denveronline.net/mailman/options/jdom-interest/youraddr@yourhost.com



More information about the jdom-interest mailing list