You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ws.apache.org by ve...@apache.org on 2012/07/12 23:37:38 UTC

svn commit: r1360964 - in /webservices/commons/trunk/modules/axiom/modules: axiom-api/src/main/java/org/apache/axiom/soap/impl/builder/SOAP11BuilderHelper.java axiom-testsuite/src/main/java/org/apache/axiom/ts/soap/builder/BadInputTest.java

Author: veithen
Date: Thu Jul 12 21:37:37 2012
New Revision: 1360964

URL: http://svn.apache.org/viewvc?rev=1360964&view=rev
Log:
Consistently use SOAPProcessingException to report violations of the SOAP specs.

Modified:
    webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/soap/impl/builder/SOAP11BuilderHelper.java
    webservices/commons/trunk/modules/axiom/modules/axiom-testsuite/src/main/java/org/apache/axiom/ts/soap/builder/BadInputTest.java

Modified: webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/soap/impl/builder/SOAP11BuilderHelper.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/soap/impl/builder/SOAP11BuilderHelper.java?rev=1360964&r1=1360963&r2=1360964&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/soap/impl/builder/SOAP11BuilderHelper.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/soap/impl/builder/SOAP11BuilderHelper.java Thu Jul 12 21:37:37 2012
@@ -92,15 +92,15 @@ public class SOAP11BuilderHelper extends
             }
 
             if (parentTagName.equals(SOAP_FAULT_CODE_LOCAL_NAME)) {
-                throw new OMBuilderException(
+                throw new SOAPProcessingException(
                         "faultcode element should not have children");
             } else if (parentTagName.equals(
                     SOAP_FAULT_STRING_LOCAL_NAME)) {
-                throw new OMBuilderException(
+                throw new SOAPProcessingException(
                         "faultstring element should not have children");
             } else if (parentTagName.equals(
                     SOAP_FAULT_ACTOR_LOCAL_NAME)) {
-                throw new OMBuilderException(
+                throw new SOAPProcessingException(
                         "faultactor element should not have children");
             } else {
                 element =

Modified: webservices/commons/trunk/modules/axiom/modules/axiom-testsuite/src/main/java/org/apache/axiom/ts/soap/builder/BadInputTest.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-testsuite/src/main/java/org/apache/axiom/ts/soap/builder/BadInputTest.java?rev=1360964&r1=1360963&r2=1360964&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-testsuite/src/main/java/org/apache/axiom/ts/soap/builder/BadInputTest.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-testsuite/src/main/java/org/apache/axiom/ts/soap/builder/BadInputTest.java Thu Jul 12 21:37:37 2012
@@ -20,10 +20,10 @@
 package org.apache.axiom.ts.soap.builder;
 
 import org.apache.axiom.om.AbstractTestCase;
-import org.apache.axiom.om.OMException;
 import org.apache.axiom.om.OMMetaFactory;
 import org.apache.axiom.om.OMXMLBuilderFactory;
 import org.apache.axiom.soap.SOAPEnvelope;
+import org.apache.axiom.soap.SOAPProcessingException;
 import org.apache.axiom.ts.AxiomTestCase;
 
 public class BadInputTest extends AxiomTestCase {
@@ -42,8 +42,8 @@ public class BadInputTest extends AxiomT
                             AbstractTestCase.getTestResource("badsoap/" + file), null)
                             .getSOAPEnvelope();
             OMTestUtils.walkThrough(soapEnvelope);
-            fail("this must failed gracefully with OMException");
-        } catch (OMException e) {
+            fail("this must failed gracefully with SOAPProcessingException");
+        } catch (SOAPProcessingException e) {
             return;
         }
     }