ws-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From veit...@apache.org
Subject svn commit: r1748050 - in /webservices/axiom/trunk: aspects/om-aspects/ aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/jaxb/ aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/mixin/ aspects/om-aspects/src/main/java/org/apache/axiom/o...
Date Sun, 12 Jun 2016 21:01:40 GMT
Author: veithen
Date: Sun Jun 12 21:01:40 2016
New Revision: 1748050

URL: http://svn.apache.org/viewvc?rev=1748050&view=rev
Log:
Deprecate the org.apache.axiom.util.stax.xop package.

Added:
    webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/ContentIDGenerator.java
      - copied, changed from r1748048, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/ContentIDGenerator.java
    webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicy.java
      - copied, changed from r1748048, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/OptimizationPolicy.java
    webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/AttachmentsMimePartProvider.java
      - copied, changed from r1748048, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java
    webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderWithDataHandlerReader.java
  (with props)
    webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java
  (props changed)
      - copied unchanged from r1682098, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java
    webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/stax/
    webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/stax/xop/   (props
changed)
      - copied from r1736651, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/
    webservices/axiom/trunk/axiom-compat/src/test/java/org/apache/axiom/util/
    webservices/axiom/trunk/axiom-compat/src/test/java/org/apache/axiom/util/stax/
    webservices/axiom/trunk/axiom-compat/src/test/java/org/apache/axiom/util/stax/xop/
      - copied from r1748048, webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/xop/
Removed:
    webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java
    webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/
    webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/xop/
Modified:
    webservices/axiom/trunk/aspects/om-aspects/pom.xml
    webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/jaxb/AttachmentUnmarshallerImpl.java
    webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/mixin/AxiomContainerSupport.aj
    webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicyImpl.java
    webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/XOPEncodingFilterHandler.java
    webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/OMXMLBuilderFactory.java
    webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/util/ElementHelper.java
    webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderUtilsTest.java
    webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/jaxb/AttachmentUnmarshallerImpl.java

Modified: webservices/axiom/trunk/aspects/om-aspects/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/pom.xml?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/om-aspects/pom.xml (original)
+++ webservices/axiom/trunk/aspects/om-aspects/pom.xml Sun Jun 12 21:01:40 2016
@@ -82,6 +82,7 @@
                         <configuration>
                             <ignore>
                                 <!-- TODO -->
+                                org.apache.axiom.om.impl.intf.AxiomContainer$AxiomContainerSupport$1
-> org.apache.axiom.om.impl.stream.xop.ContentIDGenerator,
                                 org.apache.axiom.om.impl.intf.AxiomContainer$AxiomContainerSupport$2
-> org.apache.axiom.om.impl.stream.xop.XOPEncodingFilterHandler
                             </ignore>
                         </configuration>

Modified: webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/jaxb/AttachmentUnmarshallerImpl.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/jaxb/AttachmentUnmarshallerImpl.java?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/jaxb/AttachmentUnmarshallerImpl.java
(original)
+++ webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/jaxb/AttachmentUnmarshallerImpl.java
Sun Jun 12 21:01:40 2016
@@ -19,12 +19,13 @@
 package org.apache.axiom.om.impl.jaxb;
 
 import java.io.IOException;
+import java.io.UnsupportedEncodingException;
+import java.net.URLDecoder;
 
 import javax.activation.DataHandler;
 import javax.xml.bind.attachment.AttachmentUnmarshaller;
 
 import org.apache.axiom.mime.MimePartProvider;
-import org.apache.axiom.util.stax.xop.XOPUtils;
 
 public final class AttachmentUnmarshallerImpl extends AttachmentUnmarshaller {
     private final MimePartProvider mimePartProvider;
@@ -32,6 +33,28 @@ public final class AttachmentUnmarshalle
     public AttachmentUnmarshallerImpl(MimePartProvider mimePartProvider) {
         this.mimePartProvider = mimePartProvider;
     }
+    /**
+     * Extract the content ID from a URL following the cid scheme defined by RFC2392.
+     * 
+     * @param url the URL
+     * @return the corresponding content ID
+     * @throws IllegalArgumentException if the URL doesn't use the cid scheme
+     */
+    private static String getContentIDFromURL(String url) {
+        if (url.startsWith("cid:")) {
+            try {
+                // URIs should always be decoded using UTF-8 (see AXIOM-129). On the
+                // other hand, since non ASCII characters are not allowed in content IDs,
+                // we can simply decode using ASCII (which is a subset of UTF-8)
+                return URLDecoder.decode(url.substring(4), "ascii");
+            } catch (UnsupportedEncodingException ex) {
+                // We should never get here
+                throw new Error(ex);
+            }
+        } else {
+            throw new IllegalArgumentException("The URL doesn't use the cid scheme");
+        }
+    }
 
     @Override
     public byte[] getAttachmentAsByteArray(String cid) {
@@ -42,7 +65,7 @@ public final class AttachmentUnmarshalle
     @Override
     public DataHandler getAttachmentAsDataHandler(String cid) {
         try {
-            return mimePartProvider.getDataHandler(XOPUtils.getContentIDFromURL(cid));
+            return mimePartProvider.getDataHandler(getContentIDFromURL(cid));
         } catch (IOException ex) {
             throw new RuntimeException(ex);
         }

Modified: webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/mixin/AxiomContainerSupport.aj
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/mixin/AxiomContainerSupport.aj?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/mixin/AxiomContainerSupport.aj
(original)
+++ webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/mixin/AxiomContainerSupport.aj
Sun Jun 12 21:01:40 2016
@@ -80,11 +80,11 @@ import org.apache.axiom.om.impl.stream.X
 import org.apache.axiom.om.impl.stream.sax.XMLReaderImpl;
 import org.apache.axiom.om.impl.stream.stax.pull.AxiomXMLStreamReaderExtensionFactory;
 import org.apache.axiom.om.impl.stream.stax.push.XMLStreamWriterHandler;
+import org.apache.axiom.om.impl.stream.xop.ContentIDGenerator;
+import org.apache.axiom.om.impl.stream.xop.OptimizationPolicy;
 import org.apache.axiom.om.impl.stream.xop.OptimizationPolicyImpl;
 import org.apache.axiom.om.impl.stream.xop.XOPEncodingFilterHandler;
 import org.apache.axiom.util.io.IOUtils;
-import org.apache.axiom.util.stax.xop.ContentIDGenerator;
-import org.apache.axiom.util.stax.xop.OptimizationPolicy;
 import org.xml.sax.InputSource;
 
 public aspect AxiomContainerSupport {

Copied: webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/ContentIDGenerator.java
(from r1748048, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/ContentIDGenerator.java)
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/ContentIDGenerator.java?p2=webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/ContentIDGenerator.java&p1=webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/ContentIDGenerator.java&r1=1748048&r2=1748050&rev=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/ContentIDGenerator.java
(original)
+++ webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/ContentIDGenerator.java
Sun Jun 12 21:01:40 2016
@@ -17,13 +17,13 @@
  * under the License.
  */
 
-package org.apache.axiom.util.stax.xop;
+package org.apache.axiom.om.impl.stream.xop;
 
 import org.apache.axiom.util.UIDGenerator;
 
 /**
  * Content ID generator interface. Implementations of this interface are used by
- * {@link XOPEncodingStreamReader} to generate content IDs for use in <tt>xop:Include</tt>
+ * {@link XOPEncodingFilterHandler} to generate content IDs for use in <tt>xop:Include</tt>
  * elements.
  */
 public interface ContentIDGenerator {

Copied: webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicy.java
(from r1748048, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/OptimizationPolicy.java)
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicy.java?p2=webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicy.java&p1=webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/OptimizationPolicy.java&r1=1748048&r2=1748050&rev=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/util/stax/xop/OptimizationPolicy.java
(original)
+++ webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicy.java
Sun Jun 12 21:01:40 2016
@@ -17,7 +17,7 @@
  * under the License.
  */
 
-package org.apache.axiom.util.stax.xop;
+package org.apache.axiom.om.impl.stream.xop;
 
 import java.io.IOException;
 

Modified: webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicyImpl.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicyImpl.java?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicyImpl.java
(original)
+++ webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/OptimizationPolicyImpl.java
Sun Jun 12 21:01:40 2016
@@ -26,7 +26,6 @@ import javax.activation.DataHandler;
 import org.apache.axiom.ext.stax.datahandler.DataHandlerProvider;
 import org.apache.axiom.om.OMOutputFormat;
 import org.apache.axiom.util.activation.DataHandlerUtils;
-import org.apache.axiom.util.stax.xop.OptimizationPolicy;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 

Modified: webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/XOPEncodingFilterHandler.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/XOPEncodingFilterHandler.java?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/XOPEncodingFilterHandler.java
(original)
+++ webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/stream/xop/XOPEncodingFilterHandler.java
Sun Jun 12 21:01:40 2016
@@ -28,15 +28,11 @@ import javax.activation.DataHandler;
 
 import org.apache.axiom.core.stream.StreamException;
 import org.apache.axiom.core.stream.XmlHandler;
-import org.apache.axiom.core.stream.XmlHandlerWrapper;
 import org.apache.axiom.core.stream.xop.AbstractXOPEncodingFilterHandler;
 import org.apache.axiom.core.stream.xop.CompletionListener;
 import org.apache.axiom.ext.stax.datahandler.DataHandlerProvider;
 import org.apache.axiom.mime.MimePartProvider;
 import org.apache.axiom.om.impl.intf.TextContent;
-import org.apache.axiom.util.stax.xop.ContentIDGenerator;
-import org.apache.axiom.util.stax.xop.OptimizationPolicy;
-import org.apache.axiom.util.stax.xop.XOPUtils;
 
 public final class XOPEncodingFilterHandler extends AbstractXOPEncodingFilterHandler implements
XOPHandler, MimePartProvider {
     private final Map<String,Object> dataHandlerObjects = new LinkedHashMap<String,Object>();

Copied: webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/AttachmentsMimePartProvider.java
(from r1748048, webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java)
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/AttachmentsMimePartProvider.java?p2=webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/AttachmentsMimePartProvider.java&p1=webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java&r1=1748048&r2=1748050&rev=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java
(original)
+++ webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/AttachmentsMimePartProvider.java
Sun Jun 12 21:01:40 2016
@@ -17,7 +17,7 @@
  * under the License.
  */
 
-package org.apache.axiom.om.impl.builder;
+package org.apache.axiom.om;
 
 import java.io.IOException;
 
@@ -25,16 +25,17 @@ import javax.activation.DataHandler;
 
 import org.apache.axiom.attachments.Attachments;
 import org.apache.axiom.mime.MimePartProvider;
+import org.apache.axiom.om.impl.builder.Detachable;
 
 /**
  * Adapts an {@link Attachments} instance to the {@link MimePartProvider} interface.
  * <p>
  * For internal use only.
  */
-public class AttachmentsMimePartProvider implements MimePartProvider, Detachable {
+class AttachmentsMimePartProvider implements MimePartProvider, Detachable {
     private final Attachments attachments;
 
-    public AttachmentsMimePartProvider(Attachments attachments) {
+    AttachmentsMimePartProvider(Attachments attachments) {
         this.attachments = attachments;
     }
 

Modified: webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/OMXMLBuilderFactory.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/OMXMLBuilderFactory.java?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/OMXMLBuilderFactory.java
(original)
+++ webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/OMXMLBuilderFactory.java
Sun Jun 12 21:01:40 2016
@@ -32,7 +32,6 @@ import org.apache.axiom.attachments.Atta
 import org.apache.axiom.ext.stax.datahandler.DataHandlerReader;
 import org.apache.axiom.mime.ContentType;
 import org.apache.axiom.mime.MimePartProvider;
-import org.apache.axiom.om.impl.builder.AttachmentsMimePartProvider;
 import org.apache.axiom.om.util.StAXParserConfiguration;
 import org.apache.axiom.soap.SOAPFactory;
 import org.apache.axiom.soap.SOAPModelBuilder;

Modified: webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/util/ElementHelper.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/util/ElementHelper.java?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/util/ElementHelper.java
(original)
+++ webservices/axiom/trunk/axiom-api/src/main/java/org/apache/axiom/om/util/ElementHelper.java
Sun Jun 12 21:01:40 2016
@@ -30,7 +30,6 @@ import org.apache.axiom.om.OMNode;
 import org.apache.axiom.om.ds.BlobOMDataSource;
 import org.apache.axiom.soap.SOAPFactory;
 import org.apache.axiom.soap.SOAPHeaderBlock;
-import org.apache.axiom.util.stax.xop.XOPUtils;
 
 import javax.xml.namespace.QName;
 import javax.xml.stream.XMLStreamException;
@@ -39,7 +38,9 @@ import javax.xml.stream.XMLStreamReader;
 import java.io.IOException;
 import java.io.OutputStream;
 import java.io.Reader;
+import java.io.UnsupportedEncodingException;
 import java.io.Writer;
+import java.net.URLDecoder;
 import java.util.Iterator;
 
 /**
@@ -158,7 +159,19 @@ public class ElementHelper {
      * @return the corresponding content ID
      */
     public static String getContentIDFromHref(String href) {
-        return XOPUtils.getContentIDFromURL(href);
+        if (href.startsWith("cid:")) {
+            try {
+                // URIs should always be decoded using UTF-8 (see AXIOM-129). On the
+                // other hand, since non ASCII characters are not allowed in content IDs,
+                // we can simply decode using ASCII (which is a subset of UTF-8)
+                return URLDecoder.decode(href.substring(4), "ascii");
+            } catch (UnsupportedEncodingException ex) {
+                // We should never get here
+                throw new Error(ex);
+            }
+        } else {
+            throw new IllegalArgumentException("The URL doesn't use the cid scheme");
+        }
     }
     
     /**

Modified: webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderUtilsTest.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderUtilsTest.java?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderUtilsTest.java
(original)
+++ webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderUtilsTest.java
Sun Jun 12 21:01:40 2016
@@ -33,7 +33,6 @@ import junit.framework.TestCase;
 import org.apache.axiom.om.util.StAXParserConfiguration;
 import org.apache.axiom.om.util.StAXUtils;
 import org.apache.axiom.util.base64.Base64EncodingStringBufferOutputStream;
-import org.apache.axiom.util.stax.xop.XOPDecodingStreamReader;
 import org.apache.commons.io.IOUtils;
 
 public class XMLStreamReaderUtilsTest extends TestCase {
@@ -64,10 +63,7 @@ public class XMLStreamReaderUtilsTest ex
     private void testGetDataHandlerFromElementWithZeroLength(boolean useDHR) throws Exception
{
         XMLStreamReader reader = StAXUtils.createXMLStreamReader(new StringReader("<test/>"));
         if (useDHR) {
-            // To have an XMLStreamReader that uses the DataHandlerReader extension, we wrap
-            // the parser using an XOPDecodingStreamReader (even if the document doesn't
contain
-            // any xop:Include).
-            reader = new XOPDecodingStreamReader(reader, null);
+            reader = new XMLStreamReaderWithDataHandlerReader(reader);
         }
         try {
             reader.next();
@@ -112,7 +108,7 @@ public class XMLStreamReaderUtilsTest ex
     private void testGetDataHandlerFromElementWithUnexpectedContent(boolean useDHR) throws
Exception {
         XMLStreamReader reader = StAXUtils.createXMLStreamReader(new StringReader("<test>\n<child/>\n</test>"));
         if (useDHR) {
-            reader = new XOPDecodingStreamReader(reader, null);
+            reader = new XMLStreamReaderWithDataHandlerReader(reader);
         }
         try {
             reader.next();
@@ -170,7 +166,7 @@ public class XMLStreamReaderUtilsTest ex
         XMLStreamReader reader = StAXUtils.createXMLStreamReader(StAXParserConfiguration.NON_COALESCING,
                 new StringReader(buffer.toString()));
         if (useDHR) {
-            reader = new XOPDecodingStreamReader(reader, null);
+            reader = new XMLStreamReaderWithDataHandlerReader(reader);
         }
         try {
             reader.next();

Added: webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderWithDataHandlerReader.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderWithDataHandlerReader.java?rev=1748050&view=auto
==============================================================================
--- webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderWithDataHandlerReader.java
(added)
+++ webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderWithDataHandlerReader.java
Sun Jun 12 21:01:40 2016
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.axiom.util.stax;
+
+import javax.activation.DataHandler;
+import javax.xml.stream.XMLStreamException;
+import javax.xml.stream.XMLStreamReader;
+
+import org.apache.axiom.ext.stax.datahandler.DataHandlerProvider;
+import org.apache.axiom.ext.stax.datahandler.DataHandlerReader;
+import org.apache.axiom.util.stax.wrapper.XMLStreamReaderWrapper;
+
+public class XMLStreamReaderWithDataHandlerReader extends XMLStreamReaderWrapper implements
DataHandlerReader {
+    public XMLStreamReaderWithDataHandlerReader(XMLStreamReader parent) {
+        super(parent);
+    }
+
+    @Override
+    public Object getProperty(String name) throws IllegalArgumentException {
+        Object value = XMLStreamReaderUtils.processGetProperty(this, name);
+        return value != null ? value : super.getProperty(name);
+    }
+
+    @Override
+    public boolean isBinary() {
+        return false;
+    }
+
+    @Override
+    public boolean isOptimized() {
+        throw new IllegalStateException();
+    }
+
+    @Override
+    public boolean isDeferred() {
+        throw new IllegalStateException();
+    }
+
+    @Override
+    public String getContentID() {
+        throw new IllegalStateException();
+    }
+
+    @Override
+    public DataHandler getDataHandler() throws XMLStreamException {
+        throw new IllegalStateException();
+    }
+
+    @Override
+    public DataHandlerProvider getDataHandlerProvider() {
+        throw new IllegalStateException();
+    }
+}

Propchange: webservices/axiom/trunk/axiom-api/src/test/java/org/apache/axiom/util/stax/XMLStreamReaderWithDataHandlerReader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Sun Jun 12 21:01:40 2016
@@ -0,0 +1,12 @@
+/webservices/axiom/branches/AXIOM-201/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1183599-1433135
+/webservices/axiom/branches/AXIOM-399/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1329379-1331100
+/webservices/axiom/branches/AXIOM-412/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1311325-1325526
+/webservices/axiom/branches/AXIOM-420/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1334121-1336372
+/webservices/axiom/branches/AXIOM-435/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1361507-1366198
+/webservices/axiom/branches/AXIOM-437/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1364041-1364239
+/webservices/axiom/branches/CHECK_PARENT_BUG/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1338398-1338886
+/webservices/axiom/branches/CLONE/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1337822-1339011
+/webservices/axiom/branches/CLONE_NODE/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1346607-1353106
+/webservices/axiom/branches/JAXB2_DS/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1366463-1367737
+/webservices/axiom/branches/namespaceURIInterning/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1293148-1293587
+/webservices/axiom/branches/osgi-redesign/axiom-api/src/main/java/org/apache/axiom/om/impl/builder/AttachmentsMimePartProvider.java:1180368-1180596

Modified: webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/jaxb/AttachmentUnmarshallerImpl.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/jaxb/AttachmentUnmarshallerImpl.java?rev=1748050&r1=1748049&r2=1748050&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/jaxb/AttachmentUnmarshallerImpl.java
(original)
+++ webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/jaxb/AttachmentUnmarshallerImpl.java
Sun Jun 12 21:01:40 2016
@@ -23,7 +23,7 @@ import java.io.IOException;
 import javax.activation.DataHandler;
 import javax.xml.bind.attachment.AttachmentUnmarshaller;
 
-import org.apache.axiom.mime.MimePartProvider;
+import org.apache.axiom.util.stax.xop.MimePartProvider;
 import org.apache.axiom.util.stax.xop.XOPUtils;
 
 final class AttachmentUnmarshallerImpl extends AttachmentUnmarshaller {

Propchange: webservices/axiom/trunk/axiom-compat/src/main/java/org/apache/axiom/util/stax/xop/
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Sun Jun 12 21:01:40 2016
@@ -0,0 +1,17 @@
+/webservices/axiom/branches/AXIOM-201/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1183599-1433135
+/webservices/axiom/branches/AXIOM-399/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1329379-1331100
+/webservices/axiom/branches/AXIOM-412/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1311325-1325526
+/webservices/axiom/branches/AXIOM-420/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1334121-1336372
+/webservices/axiom/branches/AXIOM-435/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1361507-1366198
+/webservices/axiom/branches/AXIOM-437/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1364041-1364239
+/webservices/axiom/branches/AXIOM-476/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1718738-1718932
+/webservices/axiom/branches/CHECK_PARENT_BUG/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1338398-1338886
+/webservices/axiom/branches/CLONE/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1337822-1339011
+/webservices/axiom/branches/CLONE_NODE/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1346607-1353106
+/webservices/axiom/branches/DOXIA-492/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1715574-1716528
+/webservices/axiom/branches/JAXB2_DS/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1366463-1367737
+/webservices/axiom/branches/attrs-aspects/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1685218-1686663
+/webservices/axiom/branches/maven-site-plugin-3.5/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1731125-1732708
+/webservices/axiom/branches/namespaceURIInterning/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1293148-1293587
+/webservices/axiom/branches/osgi-redesign/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1180368-1180596
+/webservices/axiom/branches/stax-stream/axiom-api/src/main/java/org/apache/axiom/util/stax/xop:1733528-1733796



Mime
View raw message