You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-commits@axis.apache.org by ve...@apache.org on 2012/06/30 13:28:55 UTC

svn commit: r1355706 - in /axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2: mtom/ swa/

Author: veithen
Date: Sat Jun 30 11:28:53 2012
New Revision: 1355706

URL: http://svn.apache.org/viewvc?rev=1355706&view=rev
Log:
Removed unwanted direct references to Axiom implementation classes.

Modified:
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMStreamingTest.java
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/MessageSaveAndRestoreWithMTOMTest.java
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoRawSwATest.java
    axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoSwA.java

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java Sat Jun 30 11:28:53 2012
@@ -27,7 +27,6 @@ import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.OMFactory;
 import org.apache.axiom.om.OMNamespace;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axiom.soap.SOAP12Constants;
 import org.apache.axis2.Constants;
 import org.apache.axis2.client.Options;
@@ -84,7 +83,7 @@ public class EchoRawMTOMCommonsChunkingT
         FileDataSource dataSource = new FileDataSource(fileName);
         expectedDH = new DataHandler(dataSource);
         OMElement subData = fac.createOMElement("subData", omNs);
-        OMText textData = new OMTextImpl(expectedDH, fac);
+        OMText textData = fac.createOMText(expectedDH, true);
         subData.addChild(textData);
         data.addChild(subData);
         rpcWrapEle.addChild(data);

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java Sat Jun 30 11:28:53 2012
@@ -26,7 +26,6 @@ import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.OMFactory;
 import org.apache.axiom.om.OMNamespace;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axiom.soap.SOAP12Constants;
 import org.apache.axis2.Constants;
 import org.apache.axis2.client.Options;
@@ -96,7 +95,7 @@ public class EchoRawMTOMLoadTest extends
             OMElement subData = fac.createOMElement("subData", omNs);
             DataHandler dataHandler = new DataHandler("Thilina", "text/plain");
             //new ByteArrayDataSource(expectedByteArray));
-            textData = new OMTextImpl(dataHandler, true, fac);
+            textData = fac.createOMText(dataHandler, true);
             subData.addChild(textData);
             data.addChild(subData);
 

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMStreamingTest.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMStreamingTest.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMStreamingTest.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMStreamingTest.java Sat Jun 30 11:28:53 2012
@@ -28,7 +28,6 @@ import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.OMFactory;
 import org.apache.axiom.om.OMNamespace;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axiom.soap.SOAP12Constants;
 import org.apache.axis2.Constants;
 import org.apache.axis2.addressing.EndpointReference;
@@ -94,7 +93,7 @@ public class EchoRawMTOMStreamingTest ex
                 new ByteArrayDataSource(new byte[] { 13, 56, 65, 32, 12, 12, 7, -3, -2, -1,
                         98 }));
         OMElement subData = fac.createOMElement("subData", omNs);
-        OMText textData = new OMTextImpl(expectedDH, fac);
+        OMText textData = fac.createOMText(expectedDH, true);
         subData.addChild(textData);
         data.addChild(subData);
         rpcWrapEle.addChild(data);

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java Sat Jun 30 11:28:53 2012
@@ -27,7 +27,6 @@ import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.OMFactory;
 import org.apache.axiom.om.OMNamespace;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axiom.soap.SOAP12Constants;
 import org.apache.axiom.soap.SOAPEnvelope;
 import org.apache.axis2.AxisFault;
@@ -61,7 +60,7 @@ public class EchoRawMTOMTest extends Uti
 
     private AxisService service;
 
-    private OMTextImpl expectedTextData;
+    private OMText expectedTextData;
 
     private boolean finish = false;
 
@@ -98,7 +97,7 @@ public class EchoRawMTOMTest extends Uti
         OMElement data = fac.createOMElement("data", omNs);
         FileDataSource fileDataSource = new FileDataSource(TestingUtils.prefixBaseDirectory("test-resources/mtom/test.jpg"));
         expectedDH = new DataHandler(fileDataSource);
-        expectedTextData = new OMTextImpl(expectedDH, true, fac);
+        expectedTextData = fac.createOMText(expectedDH, true);
         data.addChild(expectedTextData);
         rpcWrapEle.addChild(data);
         return rpcWrapEle;

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java Sat Jun 30 11:28:53 2012
@@ -28,7 +28,6 @@ import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.OMFactory;
 import org.apache.axiom.om.OMNamespace;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axiom.soap.SOAP12Constants;
 import org.apache.axiom.soap.SOAPEnvelope;
 import org.apache.axis2.AxisFault;
@@ -98,7 +97,7 @@ public class EchoRawMTOMToBase64Test ext
         OMElement data = fac.createOMElement("data", omNs);
         byte[] byteArray = new byte[] { 13, 56, 65, 32, 12, 12, 7, 98 };
         DataHandler dataHandler = new DataHandler(new ByteArrayDataSource(byteArray));
-        expectedTextData = new OMTextImpl(dataHandler, true, fac);
+        expectedTextData = fac.createOMText(dataHandler, true);
         data.addChild(expectedTextData);
         rpcWrapEle.addChild(data);
         return rpcWrapEle;

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/MessageSaveAndRestoreWithMTOMTest.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/MessageSaveAndRestoreWithMTOMTest.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/MessageSaveAndRestoreWithMTOMTest.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/mtom/MessageSaveAndRestoreWithMTOMTest.java Sat Jun 30 11:28:53 2012
@@ -27,7 +27,6 @@ import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.OMFactory;
 import org.apache.axiom.om.OMNamespace;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axiom.soap.SOAP12Constants;
 import org.apache.axis2.AxisFault;
 import org.apache.axis2.Constants;
@@ -69,7 +68,7 @@ import java.util.ArrayList;
  */
 public class MessageSaveAndRestoreWithMTOMTest extends UtilServerBasedTestCase
         implements TestConstants {
-    private OMTextImpl expectedTextData = null;
+    private OMText expectedTextData = null;
 
     public MessageSaveAndRestoreWithMTOMTest() {
         super(MessageSaveAndRestoreWithMTOMTest.class.getName());
@@ -165,7 +164,7 @@ public class MessageSaveAndRestoreWithMT
 
         FileDataSource fileDataSource = new FileDataSource(TestingUtils.prefixBaseDirectory("test-resources/mtom/test.jpg"));
         DataHandler expectedDataHandler = new DataHandler(fileDataSource);
-        expectedTextData = new OMTextImpl(expectedDataHandler, true, omFactory);
+        expectedTextData = omFactory.createOMText(expectedDataHandler, true);
         data.addChild(expectedTextData);
         rpcWrapperElement.addChild(data);
         return rpcWrapperElement;

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoRawSwATest.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoRawSwATest.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoRawSwATest.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoRawSwATest.java Sat Jun 30 11:28:53 2012
@@ -23,9 +23,9 @@ import junit.framework.Test;
 import junit.framework.TestSuite;
 import org.apache.axiom.om.OMAbstractFactory;
 import org.apache.axiom.om.OMElement;
+import org.apache.axiom.om.OMFactory;
 import org.apache.axiom.om.OMNamespace;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axiom.soap.SOAP11Constants;
 import org.apache.axiom.soap.SOAPEnvelope;
 import org.apache.axiom.soap.SOAPFactory;
@@ -132,8 +132,9 @@ public class EchoRawSwATest extends Util
     }
 
     protected void compareDataHandlers(DataHandler dataHandler, DataHandler dataHandler2) {
-        String originalTextValue = new OMTextImpl(dataHandler, true, null).getText();
-        String returnedTextValue = new OMTextImpl(dataHandler2, true, null).getText();
+        OMFactory factory = OMAbstractFactory.getOMFactory();
+        String originalTextValue = factory.createOMText(dataHandler, true).getText();
+        String returnedTextValue = factory.createOMText(dataHandler2, true).getText();
         assertEquals(returnedTextValue, originalTextValue);
     }
 }
\ No newline at end of file

Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoSwA.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoSwA.java?rev=1355706&r1=1355705&r2=1355706&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoSwA.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/swa/EchoSwA.java Sat Jun 30 11:28:53 2012
@@ -23,7 +23,6 @@ import org.apache.axiom.attachments.Atta
 import org.apache.axiom.om.OMAttribute;
 import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.OMText;
-import org.apache.axiom.om.impl.llom.OMTextImpl;
 import org.apache.axis2.AxisFault;
 import org.apache.axis2.context.MessageContext;
 import org.apache.axis2.wsdl.WSDLConstants;
@@ -51,7 +50,7 @@ public class EchoSwA {
         Attachments attachment = (msgCtx).getAttachmentMap();
 
         DataHandler dataHandler = attachment.getDataHandler(contentID);
-        OMText textNode = new OMTextImpl(dataHandler, omEle.getOMFactory());
+        OMText textNode = omEle.getOMFactory().createOMText(dataHandler, true);
         omEle.build();
         child.detach();
         omEle.addChild(textNode);