cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Giacomo Pati <>
Subject Re: possible bug in xsp engine in c2
Date Mon, 30 Oct 2000 18:23:48 GMT
On Mon, Oct 30, 2000 at 01:56:15PM -0000, Sebastien Sahuc wrote:
> > // Create a new element <xsp:text that wrap the quoted PCDATA
> > super.startElement(Constants.XSP_URI, "text", "xsp:text",new 
> > AttributesImpl() );
> > super.characters(value.toCharArray(), 0, value.length());
> > super.endElement(Constants.XSP_URI, "text", "xsp:text");
> > 
> > now, to my eye, the qname parameter of the startElement and endElement
> > method calls is unnecessary and potentially wrong. we don't 
> > _know_ that
> > the xsp uri is going to be mapped to the 'xsp' prefix on the 
> > xsp page. the
> > SAX2 api docs imply that i can simply use an empty string instead of
> > "xsp:text" here - but when i try that, i get incorrect results. am i
> > misusing SAX2 or am i exposing a more subtle error?
> Donald, 
> I agree with you that no code should rely on the 'xsp:' prefix, but rather
> on it's declared namespace URI. 
> Unfortunately, it's not that simple because we setup the reader with the
> prefix-namespace property 'on', which simply means that the qname cannot be
> an empty string but instead is a value aggregating the prefix along with the
> local name.
> So the question is rather should we still make use of the prefix-namespace
> feature, and therefore depend on the prefix part, or should we be 100%
> prefix independant ? Honestly I would better see the second option, but that
> means some work to do ...

I've talked with Ricardo about the design of the XSP engine. The 
design was made for a DOM model and we should adapt a better design 
for the SAX model. As far as I remember Ricardo will contact you, 
Sebastien, to share his visions about how such a design can look like. 
So either you contact him or he will contact you sometimes. I don't 
know where he was leaving after ApacheCon (back to Columbia or to his
new employer in Italy).


PWR GmbH, Organisation & Entwicklung      Tel:   +41 (0)1  856 2202
Giacomo Pati, CTO/CEO                     Fax:   +41 (0)1  856 2201
Hintereichenstrasse 7                     Mobil: +41 (0)78 759 7703
CH-8166 Niederweningen          

View raw message