[jdom-interest] HOw to do this in jdom?

Roman Rytov rrytov at entopia.com
Tue Oct 22 10:06:10 PDT 2002

I'm not sure my way is the best but to specify namespaces I had to add a dummy attribute that in your case may be like:

  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" rdf:dum="1"
  xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" sy:dum="1"
  xmlns="http://purl.org/rss/1.0/" dum="1"

if it doesn't disturb you then by help of JDom you may achive it when you add an attribute to en element:"

Namespace yourNamespace = Namespace.getNamespace( "rdf" , "http://www.w3.org/1999/02/22-rdf-syntax-ns#" );
element.setAttribute( "dum" , "1" , yourNamespace );

Again, I've not using JDom a lot but when I needed it I found this workaround. Hope the others'll reveal a better/righter solution.


-----Original Message-----
From: xavi [mailto:escufi at menta.net]
Sent: Tuesday, October 22, 2002 6:25 PM
To: jdom-interest at jdom.org
Subject: [jdom-interest] HOw to do this in jdom?

i dont know to do this... and my english its very bad...sorry... ho w to do


Computing is a race between the universe and engineers. Engineers trying to
develop better idiot proof software, and the universe trying to make better

To control your jdom-interest membership:

More information about the jdom-interest mailing list