cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carsten Ziegeler" <cziege...@sundn.de>
Subject AW: [c2] bug in DOMBuilder stuff
Date Mon, 23 Apr 2001 06:35:16 GMT
Hi,

I found a problem with the DOMBuilder several month ago and noone could
answer this. My email was:

>>>
Hello,
 
I have the following problem with the org.apache.cocoon.xml.dom.DOMBuilder
and entities:
Usually for an entity like &amp; three SAX events are generated 
by the parser:
startEntity("amp"), characters("&") and endEntity("amp").
If i pass these events to a DOMBuilder I get an "Modification not allowed"
Exception on the characters event.
(I send before the startEntity event, the following events: 
startDocument(),
startElement(...)).
 
Is this a bug of the DOMBuilder or did I get something wrong?
<<<<
No the fix I use is to not set the lexicalHandler if the DOMBuilder is used,
so the startEntity and endEnitity events are not send to the DOMBuilder.
Perhaps this helps with your problem, too.


Carsten 

Open Source Group                        sunShine - b:Integrated
================================================================
Carsten Ziegeler, S&N AG, Klingenderstrasse 5, D-33100 Paderborn
www.sundn.de                          mailto: cziegeler@sundn.de 
================================================================


> -----Ursprungliche Nachricht-----
> Von: Donald Ball [mailto:balld@webslingerZ.com]
> Gesendet: Montag, 23. April 2001 03:38
> An: cocoon-dev@xml.apache.org
> Betreff: [c2] bug in DOMBuilder stuff
> 
> 
> heya. i was just dusting off the xinclude transformer to try to compare it
> to the sitemap aggregation features. anyway, i tried it out on an xinclude
> with an embedded xpath expression and i got this:
> 
> mentorg.w3c.dom.DOMException: DOM001 Modification not allowed
>         at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:969)
> at org.apache.cocoon.components.parser.JaxpParser.parse(JaxpParser.java:
> 66)        at
> org.apache.cocoon.transformation.XIncludeTransformer.processXIncludeE
> lement(XIncludeTransformer.java:252)
>         at
> org.apache.cocoon.transformation.XIncludeTransformer.startElement(
> XIncludeTransformer.java:129)
>         at
> org.apache.cocoon.xml.AbstractXMLPipe.startElement(AbstractXMLPipe
> .java:90)
> 
> the relevant snippet of code is:
> 
>   DOMBuilder builder = new DOMBuilder(parser);
>   parser.setContentHandler(builder);
>   parser.setLexicalHandler(builder);
>   parser.parse(input);
> 
> anyone got an idea why this fails now?
> 
> - donald
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message