axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eric Johnson <>
Subject Re: [Axis2] Two OM questions - serialize with cache and "optimize".
Date Fri, 30 Sep 2005 20:16:00 GMT
Thanks for the response.

That seems weird, though.  That means if you call the serialize function 
(without the cache), the OMDocument can effectively be corrupted.

I found myself putting this comment on OMDocument.serialize()

     * <p>Caution: Serializing without caching means that any portion of 
the document
     * that has not been read will no longer be available for further 
     * In other words, this function can corrupt the remainder of your 
     * Only use it when you're sure you know longer need the contents of 
the document.</p>

Should the function also somehow mark the document then, so that 
OMDocumentImpl.buildNext() throws an exception?


Davanum Srinivas wrote:

>Hehehe...i asked the same question #1 last week when i met Eran in
>Synapse F2F. Eran, Please check if my understanding below is correct.
>Suppose you are building an om structure by reading stuff from a
>stream and you are half-way through it you want to serialize
>everything (including the stuff for which OM has not been built in
>memory) then you can call serialize. So AFTER you serialize you lose
>the info for which om was not built already. So if you want to build
>the OM *AND* serialize the input to output, then you call
>Need to check on #2
>-- dims
>On 9/30/05, Eric Johnson <> wrote:
>>I've got two OM questions at the moment:
>>1) What the heck does "OMNode.serializeWithCache()" mean?  How is it
>>different from "OMNode.serialize()"?  I was hoping to put some Javadoc
>>on the function(s) but couldn't figure out from inspection what the
>>substantive difference was.
>>2) What is the OMText "optimized" property?  It is never set via
>>"setOptimized", and never inspected via "isOptimized."  I'm guessing
>>that this was meant to be the "optimized" part of MTOM, but since it is
>>never set or used, is it worth keeping?
>Davanum Srinivas : - Oxygenating The Web Service Platform

View raw message