Sylvain Wallez wrote: > > Hi all, > > I've tried to use the new namespace-aware Configurations and encountered > serious problems : each Configuration is given the latest namespaces > declared whatever its actual namespace is. > > For example : > <?xml version='1.0'?> > <ns2:config xmlns:ns1='namespace-1' xmlns:ns2='namespace-2'> > <ns1:child name='child-config'> > <foo>value of blah</foo> > </ns1:child> > </ns2:config> > leads to all elements being marked as belonging to "ns2" (the latest one > declared). > > So please find attached a patch for both SAXConfigurationHandler and > DefaultConfigurationSerializer.
Thanks. > But there's another important issue : configurations are given the > prefixed name of the XML element (e.g. "ns2:config" and "ns1:child"). I > think this is wrong : namespace prefix is only XML syntactic sugar and > doesn't have any semantic meaning (you can give any prefix to a > namespace). Having prefixed names obliges either the configuration file > to use predefined XML prefixes (we've seen on Cocoon how error prone > this can be) or the application to manually strip prefixes when > processing the configuration. I agree. They should be localName only--the Namespace object is to cache the prefix/uri. -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>