geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aaron Mulder <>
Subject Re: Namespaces, was: XMLBeans for DDs
Date Sat, 21 Feb 2004 14:16:25 GMT
	I guess my hope would be that in the example below, the n1 prefix 
would be inherited by the children, so in essence it was legal to refer to 
the first child with either "n1" or "n2" and the second child with either 
"n1" or "n3".  I wouldn't expect that to be the case if the URIs were 
different, but in the case we're interested in, they'll all map to the 
same J2EE namespace.

	Of course, it does beg the question, in the example given in the
J2EE spec, how can you determine the namespace for the embedded vendor
content?  Because to state it more succintly, you can't find the prefix
for any node until you traverse to the node...


On Sat, 21 Feb 2004, Jeremy Boynes wrote:
> The xpaths all refer to elements in the j2ee namespace and so I don't 
> think there is any need to qualify them. It is the tool's responsibility 
> to make sure that the queries are properly mapped into that namespace.
> > <n1:parent xmlns:n1="myuri">
> >   <n2:child xmlns:n2="myuri"/>
> >   <n3:child xmlns:n3="myuri"/>
> > </n1:parent>
> > 
> > Is this legal xml?  What xpath can you use to find the chlid elements?
> > 
> Yes. The namespace for all of these is "myuri" but I am not sure how you 
> express that in xpath - certainly not in the simplified way 88 shows. 
> But I don't think it matters.
> --
> Jeremy

View raw message