From cocoon-dev-return-20240-apmail-xml-cocoon-dev-archive=xml.apache.org@xml.apache.org Thu Dec 20 21:07:02 2001 Return-Path: Delivered-To: apmail-xml-cocoon-dev-archive@xml.apache.org Received: (qmail 45664 invoked by uid 500); 20 Dec 2001 21:07:02 -0000 Mailing-List: contact cocoon-dev-help@xml.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: cocoon-dev@xml.apache.org Delivered-To: mailing list cocoon-dev@xml.apache.org Received: (qmail 45653 invoked from network); 20 Dec 2001 21:07:02 -0000 From: "Vadim Gritsenko" To: Subject: RE: [vote] Removing namespace-prefixes feature on parsers Date: Thu, 20 Dec 2001 16:03:55 -0500 Message-ID: <005701c18999$d6bc97d0$90a4558b@vgritsenkopc> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.2616 In-Reply-To: <3C221A53.F60BB9C8@anyware-tech.com> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Importance: Normal X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N I'm not a namespace guru... ;) If this does not break anything, count me in: +1. Vadim > -----Original Message----- > From: Sylvain Wallez [mailto:sylvain.wallez@anyware-tech.com] > Sent: Thursday, December 20, 2001 12:05 PM > To: cocoon-dev > Subject: [vote] Removing namespace-prefixes feature on parsers > > Hi team, > > The default behaviour of a SAX parser when encountering an xmlns:xxx > namespace declaration is to call ContentHandler.startPrefixMapping(), > and to remove this attribute from the Attributes object passed to > startElemnt(). > > But Cocoon code also sets the "namespace-prefixes" feature each time it > creates a Parser. This has the effect of also passing xmlns:xxx in the > Attributes (see ContentHandler.startElement() javadocs for more > details). > > What is the reason for enabling this feature ? I guess this was a try to > circumvent a long-standing (still present) bug in Xalan's serializer > which doesn't output properly namespace declarations if they're not > present as attributes in the incoming SAX stream. However, this wasn't > the solution and I patched several months ago AbstractTextSerializer to > make Xalan happy. > > Now I'm using Saxon for some parts of our apps and this one barks on > each and every xmlns:xxx attribute it encounters when reading > stylesheets. So I locally removed the namespace-prefixes feature : this > fixes Saxon problems and doesn't hurt Xalan (it needs them only for > proper serialization). > > So, team, what about not enabling the "namespace-prefix" feature and > thus keep the default behaviour of SAX parsers ? > > +1 from me. > > Sylvain. > > -- > Sylvain Wallez > Anyware Technologies - http://www.anyware-tech.com > --------------------------------------------------------------------- To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org For additional commands, email: cocoon-dev-help@xml.apache.org