[jdom-interest] cant achive creation of this xml tag with jdom

eial at cs.bgu.ac.il eial at cs.bgu.ac.il
Tue Mar 25 00:22:23 PDT 2008


ok, another question, how can I access childs or attributes of an element which has two namespaces?
On Tue 25 Mar 8:14 2008 eial at cs.bgu.ac.il wrote:
> it's not that I want, its that I need... I think that I'll have to go about it the other way
> 
> On Tue 25 Mar 1:26 2008 Rolf wrote:
> > JDom is right.
> > 
> > You can't have an undeclared namespace declaration:
> > 
> > http://www.w3.org/TR/2006/REC-xml-names-20060816/#ns-qualnames
> > 
> > Qualified name stream:features must be associated with a namespace 
> > declaration.
> > 
> > You must declare the namespace as specified in:
> > 
> > http://www.w3.org/TR/2006/REC-xml-names-20060816/#ns-decl
> > 
> > Rolf
> > 
> > eial at cs.bgu.ac.il wrote:
> > >
> > > hello, I need to create this xml tag using jdom in java:
> > > Code:
> > >
> > > <stream:features>
> > >   <bind xmlns="urn:ietf:params:xml:ns:xmpp­-bind" />
> > >   <session xmlns="urn:ietf:params:xml:ns:xmpp­-session" />
> > > </stream:features>
> > >
> > >
> > > the closest I've been able to get is this:
> > > Code:
> > >
> > > <stream:features xmlns:stream="features">
> > >   <bind xmlns="urn:ietf:params:xml:ns:xmpp-­bind" />
> > >   <session xmlns="urn:ietf:params:xml:ns:xmpp-­session" />
> > > </stream:features>
> > >
> > > I've cant seems to remove the added xmlns attribute in the main.
> > > how can I remove it, thanks.
> > > ------------------------------------------------------------------------
> > >
> > > _______________________________________________
> > > To control your jdom-interest membership:
> > > http://www.jdom.org/mailman/options/jdom-interest/youraddr@yourhost.com
> > 
> 
> 
> 
> 
> _______________________________________________
> To control your jdom-interest membership:
> http://www.jdom.org/mailman/options/jdom-interest/youraddr@yourhost.com
> 






More information about the jdom-interest mailing list