[jdom-interest] Namespace handling ?

Christophe D. Laprun chris.laprun at nist.gov
Mon Jun 26 09:25:08 PDT 2000

Hi all,

Can someone help me with this, please ? I am not sure if it is JDOM
specific though... I tried to put namespace-prefix to false in
SAXBuilder with
false) but it didn't change anything and I don't understand why.
Any help would be greatly appreciated.

> I am trying to create a (not so) simple XML file without a namespace but
> each time I try to parse it (using SAXBuilderDemo), I get the following
> error:
> org.jdom.IllegalNameException: The name "" is not legal for JDOM/XML
> namespaces: Namespace URIs must be non-null and non-empty Strings..
>         at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1225)
>         at org.jdom.input.SAXBuilder.build(SAXBuilder.java:220)
>         at org.jdom.input.SAXBuilder.build(SAXBuilder.java:287)
>         at org.jdom.input.SAXBuilder.build(SAXBuilder.java:268)
>         at SAXBuilderDemo.testBuilder(SAXBuilderDemo.java:99)
>         at SAXBuilderDemo.main(SAXBuilderDemo.java:136)
> Note also that there is a (very) minor bug since the message contains
> two periods... Anyway, is there a way not to use namespaces (I cannot
> think it is impossible) ? Am I doing something wrong ?  

Thanks a lot.


Christophe Laprun    [Ingenieur ISIMA, France / Guest researcher @NIST]
web: http://www.nist.gov/speech/laprunch.htm
email: chris.laprun at nist.gov
phone: (301) 975 3191             fax: (301) 670 0939
The universe seems neither benign nor hostile, merely indifferent -

More information about the jdom-interest mailing list