[jdom-interest] Why do I get xmlns="" ?

Hainer, Neil hainern at jivanet.net
Tue Nov 18 16:55:09 PST 2003


Hi,


The following code snippet:

 Element description = new Element( "Description", rdfNameSpace );
 description.setAttribute( "about", rdfID + "-" + counter + "a", rdfNameSpace );
 description.addContent( "    \n" );
 Element namehunterScore = new Element( "namehunterScore" );
 namehunterScore.setText( score );
 description.addContent( "        " );
 description.addContent( namehunterScore );
 description.addContent( "\n    " );

produces the following output:

    <rdf:Description rdf:about="TPM08785-2a">    
        <namehunterScore xmlns="">1.000000</namehunterScore>
    </rdf:Description>

why does the namehunterScore element contain the attribute xmlns=""?

I am using the beta9 release of JDOM.

TIA,

Neil





More information about the jdom-interest mailing list