You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commons-dev@ws.apache.org by se...@apache.org on 2009/09/20 17:26:45 UTC

svn commit: r817042 - /webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java

Author: senaka
Date: Sun Sep 20 15:26:42 2009
New Revision: 817042

URL: http://svn.apache.org/viewvc?rev=817042&view=rev
Log:
Fixing WSCOMMONS-502.

Modified:
    webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java

Modified: webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java?rev=817042&r1=817041&r2=817042&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java Sun Sep 20 15:26:42 2009
@@ -317,4 +317,16 @@
                                      boolean includeXMLDeclaration) throws XMLStreamException {
         OMDocumentImplUtil.internalSerialize(this, writer, cache, includeXMLDeclaration);
     }
+
+    /** Serializes the document with the XML declaration. */
+    public void internalSerializeAndConsume(XMLStreamWriter writer)
+            throws XMLStreamException {
+        internalSerialize(writer, false);
+    }
+
+
+    /** Serializes the document with cache. */
+    public void internalSerialize(XMLStreamWriter writer) throws XMLStreamException {
+        internalSerialize(writer, true);
+    }
 }



Re: svn commit: r817042 - /webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java

Posted by Senaka Fernando <se...@gmail.com>.
Hi Andreas,

Thanks for picking this up. I should have mailed the list soon after my
commit.

On Sun, Sep 20, 2009 at 9:34 PM, Andreas Veithen
<an...@gmail.com>wrote:

> Senaka,
>
> I fixed WSCOMMONS-502 already with the change in r816761 (which is
> slightly more generic than the patch proposed in the JIRA). Therefore,
> your change is redundant and should not be necessary.
>

No it is not redundant. I saw that you added the modifications to
OMNodeImpl, but Abdera also uses OMDocumentImpl which doesn't extend
OMNodeImpl. And hence my commit. We can perhaps deprecate these two methods
as well, and remove them later. I was able to compile and run Abdera
successfully with this change. OTOH, If we are going to continue having the
two methods,

internalSerialize(XMLStreamWriter writer, boolean cache)
internalSerialize(XMLStreamWriter writer, boolean cache, boolean
includeXMLDeclaration)

I see nothing wrong in having the other two as well. They are simply
convenience methods.

Thanks,
Senaka.

>
> Andreas
>
> On Sun, Sep 20, 2009 at 17:26,  <se...@apache.org> wrote:
> > Author: senaka
> > Date: Sun Sep 20 15:26:42 2009
> > New Revision: 817042
> >
> > URL: http://svn.apache.org/viewvc?rev=817042&view=rev
> > Log:
> > Fixing WSCOMMONS-502.
> >
> > Modified:
> >
>  webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java
> >
> > Modified:
> webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java
> > URL:
> http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java?rev=817042&r1=817041&r2=817042&view=diff
> >
> ==============================================================================
> > ---
> webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java
> (original)
> > +++
> webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java
> Sun Sep 20 15:26:42 2009
> > @@ -317,4 +317,16 @@
> >                                      boolean includeXMLDeclaration)
> throws XMLStreamException {
> >         OMDocumentImplUtil.internalSerialize(this, writer, cache,
> includeXMLDeclaration);
> >     }
> > +
> > +    /** Serializes the document with the XML declaration. */
> > +    public void internalSerializeAndConsume(XMLStreamWriter writer)
> > +            throws XMLStreamException {
> > +        internalSerialize(writer, false);
> > +    }
> > +
> > +
> > +    /** Serializes the document with cache. */
> > +    public void internalSerialize(XMLStreamWriter writer) throws
> XMLStreamException {
> > +        internalSerialize(writer, true);
> > +    }
> >  }
> >
> >
> >
>

Re: svn commit: r817042 - /webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java

Posted by Andreas Veithen <an...@gmail.com>.
Senaka,

I fixed WSCOMMONS-502 already with the change in r816761 (which is
slightly more generic than the patch proposed in the JIRA). Therefore,
your change is redundant and should not be necessary.

Andreas

On Sun, Sep 20, 2009 at 17:26,  <se...@apache.org> wrote:
> Author: senaka
> Date: Sun Sep 20 15:26:42 2009
> New Revision: 817042
>
> URL: http://svn.apache.org/viewvc?rev=817042&view=rev
> Log:
> Fixing WSCOMMONS-502.
>
> Modified:
>    webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java
>
> Modified: webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java
> URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java?rev=817042&r1=817041&r2=817042&view=diff
> ==============================================================================
> --- webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java (original)
> +++ webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMDocumentImpl.java Sun Sep 20 15:26:42 2009
> @@ -317,4 +317,16 @@
>                                      boolean includeXMLDeclaration) throws XMLStreamException {
>         OMDocumentImplUtil.internalSerialize(this, writer, cache, includeXMLDeclaration);
>     }
> +
> +    /** Serializes the document with the XML declaration. */
> +    public void internalSerializeAndConsume(XMLStreamWriter writer)
> +            throws XMLStreamException {
> +        internalSerialize(writer, false);
> +    }
> +
> +
> +    /** Serializes the document with cache. */
> +    public void internalSerialize(XMLStreamWriter writer) throws XMLStreamException {
> +        internalSerialize(writer, true);
> +    }
>  }
>
>
>