Hi, Thank you for replying. Do you have an idea how can read the content of an element as String? I have an element called <owql:OWLQL>, this element has mor subelements which I need to have as String, here is my xml fragment:
<owql:OWLQL xmlns:owql ="http://maria_sharapova.html"> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <SOAP-ENV:Body> <owl-ql:query xmlns:owl-ql="http://www.w3.org/2003/10/owl-ql-syntax#" xmlns:var="http://www.w3.org/2003/10/owl-ql-variables#" xmlns:iw="http://www.ksl.stanford.edu/software/IW/spec/iw.daml#" xmlns:tkb="http://ksl.stanford.edu/ksl-tony-hall-demo.urn#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns:owl="http://www.w3.org/2002/07/owl#" xmlns:daml="http://www.daml.org/2001/03/daml+oil#"> <owl-ql:queryPattern> <owl-ql:KIF>(and (|http://www.w3.org/1999/02/22-rdf-syntax-ns#|::type ~visit |http://www.ksl.stanford.edu/projects/Aquaint/AquaSumo.daml#|::|Visit|) (|http://reliant.teknowledge.com/DAML/SUMO.daml#|::located ~visit |http://reliant.teknowledge.com/DAML/CountriesAndRegions.daml#|::|Iraq|) (|http://www.ksl.stanford.edu/projects/Aquaint/AquaSumo.daml#|::visitor ~visit ?who) (/= ?who |http://www.ksl.stanford.edu/projects/Aquaint/TonyHall.daml#|::|TonyHall|) (|http://reliant.teknowledge.com/DAML/SUMO.daml#|::member ?who |http://www.ksl.stanford.edu/projects/Aquaint/AquaSumo.daml#|::|UnitedStatesCong ress|) (precedes (whenfn |http://www.ksl.stanford.edu/projects/Aquaint/AquaSumo.daml#|::|GulfWar|) (whenfn ~visit)))</owl-ql:KIF> </owl-ql:queryPattern> <owl-ql:answerPattern> <rdf:RDF><rdf:Description rdf:about="has"> <var:who>also</var:who> </rdf:Description> </rdf:RDF> </owl-ql:answerPattern> <owl-ql:mustBindVars> <var:who/></owl-ql:mustBindVars> <owl-ql:answerKBPattern> <owl-ql:kbRef rdf:resource="http://ksl.stanford.edu/ksl-tony-hall-demo.urn"/></owl-ql:answerKB Pattern> </owl-ql:query> </SOAP-ENV:Body> </SOAP-ENV:Envelope> </owql:OWLQL> So I need the fragment <SOAP-ENV:Envelope>. Thanks, Halgurt >X-Sieve: CMU Sieve 2.2 >Delivered-To: [EMAIL PROTECTED] >Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm >list-help: <mailto:[EMAIL PROTECTED]> >list-unsubscribe: <mailto:[EMAIL PROTECTED]> >list-post: <mailto:[EMAIL PROTECTED]> >Delivered-To: mailing list [EMAIL PROTECTED] >X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=RCVD_BY_IP,SPF_HELO_PASS,SPF_PASS >X-Spam-Check-By: apache.org >Date: Thu, 19 Aug 2004 12:05:45 +0200 >From: Gianugo Rabellino <[EMAIL PROTECTED]> >To: [EMAIL PROTECTED] >Subject: Re: characters() strange behavior >Mime-Version: 1.0 >Content-Transfer-Encoding: 7bit >X-Virus-Checked: Checked >X-Virus-Scanned: by amavisd-new/sophie/sophos at mailin1.informatik.tu-muenchen.de >X-Spam-Checker-Version: SpamAssassin 2.64-tuminfo_0 (2004-01-11) on mailin1.informatik.tu-muenchen.de >X-Spam-Level: >X-Spam-Status: No, hits=-4.9 required=7.0 tests=BAYES_00 autolearn=ham version=2.64-tuminfo_0 >X-Virus-Scanned: by amavisd-new/sophie/sophos at mailrelay1.informatik.tu-muenchen.de > >On Thu, 19 Aug 2004 10:54:54 +0200 (MEST), Halgurt Mustafa-Ali ><[EMAIL PROTECTED]> wrote: >> Hi, >> >> I had a look at the cocoon API to find out how the method "Characters" I found >> this section below: >[...] >> c should be the whole characters of the xml document, but when I have documents >> who have more characters than 2048 I get only the first 2048 and the rest will >> be cut. Can somebody give me an explanation? > >A good read at the SAX API should clarify your problem. the characters >will be sent you as an unspecified number of characters() calls to >your handler, so you are probably missing the second one (your parser >is doing 2048 chars chunks). > >Mind you, pay special attention to the "start" and "len" parameter: >the char array can be reused so that if a first event sends you >"greetings" and the next one sends you "world", the first array will >be > >g r e e t i n g s > >and the second one could be > >w o r l d i n g s > >or even > >g r e e w o r l d > >or, why not, > >g r w o r l d g s > >I'm not saying this is happening (well, the first and secondd scenario >are, actually), but the spec explicitely say it might. > >Ciao, > >-- >Gianugo Rabellino >