Make Spring WS work with both Axiom 1.2 and Axiom 1.3/1.4.

See #1264.
This commit is contained in:
Greg L. Turnquist
2022-10-27 12:00:00 -05:00
parent cce6722329
commit 9c0e99d4dc
64 changed files with 1282 additions and 163 deletions

52
Jenkinsfile vendored
View File

@@ -22,12 +22,26 @@ pipeline {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=distribute,convergence ci/test.sh"
sh "PROFILE=distribute,convergence,testing ci/test.sh"
}
}
stage("Test other configurations") {
parallel {
stage("Test: Axiom 1.3)") {
agent {
docker {
image 'adoptopenjdk/openjdk8:latest'
args '-v $HOME/.m2:/root/.m2'
}
}
environment {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=axiom-1.3,convergence,testing ci/test.sh"
}
}
stage("Test: spring-buildsnapshot (jdk8)") {
agent {
docker {
@@ -39,7 +53,35 @@ pipeline {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=spring-buildsnapshot,convergence ci/test.sh"
sh "PROFILE=spring-buildsnapshot,convergence,testing ci/test.sh"
}
}
stage("Test: spring-security-5.6 (jdk8)") {
agent {
docker {
image 'adoptopenjdk/openjdk8:latest'
args '-v $HOME/.m2:/root/.m2'
}
}
environment {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=spring-security-5.6,convergence,testing ci/test.sh"
}
}
stage("Test: spring-security-5.7 (jdk8)") {
agent {
docker {
image 'adoptopenjdk/openjdk8:latest'
args '-v $HOME/.m2:/root/.m2'
}
}
environment {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=spring-security-5.7,convergence,testing ci/test.sh"
}
}
stage("Test: baseline (jdk11)") {
@@ -53,7 +95,7 @@ pipeline {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=distribute,java11,convergence ci/test.sh"
sh "PROFILE=distribute,java11,convergence,testing ci/test.sh"
}
}
stage("Test: spring-buildsnapshot (jdk11)") {
@@ -67,7 +109,7 @@ pipeline {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=spring-buildsnapshot,java11,convergence ci/test.sh"
sh "PROFILE=spring-buildsnapshot,java11,convergence,testing ci/test.sh"
}
}
stage("Test: spring-buildsnapshot (jdk16)") {
@@ -81,7 +123,7 @@ pipeline {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
}
steps {
sh "PROFILE=spring-buildsnapshot,java11,convergence ci/test.sh"
sh "PROFILE=spring-buildsnapshot,java11,convergence,testing ci/test.sh"
}
}
}

62
pom.xml
View File

@@ -88,7 +88,10 @@
<activemq.version>4.1.2</activemq.version>
<aspectj.version>1.9.6</aspectj.version>
<assertj.version>3.9.0</assertj.version>
<axiom.version>1.2.20</axiom.version>
<axiom-1.2.version>1.2.20</axiom-1.2.version>
<axiom-1.3.version>1.3.0</axiom-1.3.version>
<axiom-1.4.version>1.4.0</axiom-1.4.version>
<axiom.version>${axiom-1.4.version}</axiom.version>
<commons-httpclient.version>3.1</commons-httpclient.version>
<commons-io.version>2.5</commons-io.version>
<dom4j.version>1.6.1</dom4j.version>
@@ -109,8 +112,8 @@
<slf4j.version>1.7.25</slf4j.version>
<smack.version>4.2.1</smack.version>
<soap-api.version>1.4.0</soap-api.version>
<spring.version>5.3.17</spring.version>
<spring-security.version>5.5.5</spring-security.version>
<spring.version>5.3.23</spring.version>
<spring-security.version>5.5.8</spring-security.version>
<stax.version>1.8.3</stax.version>
<sun-mail.version>1.6.0</sun-mail.version>
<woodstox.version>4.2.0</woodstox.version>
@@ -228,11 +231,28 @@
</build>
<profiles>
<profile>
<id>axiom-1.3</id>
<properties>
<axiom.version>${axiom-1.3.version}</axiom.version>
</properties>
</profile>
<profile>
<id>spring-buildsnapshot</id>
<properties>
<spring.version>5.3.18-SNAPSHOT</spring.version>
<spring-security.version>5.5.6-SNAPSHOT</spring-security.version>
<spring.version>5.3.24-SNAPSHOT</spring.version>
</properties>
</profile>
<profile>
<id>spring-security-5.6</id>
<properties>
<spring-security.version>5.6.8</spring-security.version>
</properties>
</profile>
<profile>
<id>spring-security-5.7</id>
<properties>
<spring-security.version>5.7.4</spring-security.version>
</properties>
</profile>
@@ -286,6 +306,17 @@
</build>
</profile>
<profile>
<id>testing</id>
<modules>
<module>spring-ws-core</module>
<module>spring-ws-security</module>
<module>spring-ws-support</module>
<module>spring-xml</module>
<module>spring-ws-tests</module>
</modules>
</profile>
<profile>
<id>distribute</id>
@@ -699,6 +730,17 @@
<useSystemClassLoader>false</useSystemClassLoader>
<argLine>
--illegal-access=permit
--add-opens java.base/java.lang=ALL-UNNAMED
--add-opens java.base/java.lang=ALL-UNNAMED
--add-opens java.xml/com.sun.org.apache.xerces.internal.parsers=ALL-UNNAMED
--add-opens java.xml/com.sun.org.apache.xerces.internal.util=ALL-UNNAMED
--add-opens java.xml.crypto/com.sun.org.apache.xml.internal.security=ALL-UNNAMED
--add-opens java.xml.crypto/org.jcp.xml.dsig.internal.dom=ALL-UNNAMED
--add-exports java.base/java.lang=ALL-UNNAMED
--add-exports java.xml/com.sun.org.apache.xerces.internal.parsers=ALL-UNNAMED
--add-exports java.xml/com.sun.org.apache.xerces.internal.util=ALL-UNNAMED
--add-exports java.xml.crypto/com.sun.org.apache.xml.internal.security=ALL-UNNAMED
--add-exports java.xml.crypto/org.jcp.xml.dsig.internal.dom=ALL-UNNAMED
</argLine>
</configuration>
</plugin>
@@ -744,10 +786,6 @@
<artifactId>saaj-impl</artifactId>
<version>${saaj-impl.version}</version>
<exclusions>
<exclusion>
<groupId>javax.xml.soap</groupId>
<artifactId>javax.xml.soap-api</artifactId>
</exclusion>
<exclusion>
<groupId>jakarta.xml.soap</groupId>
<artifactId>jakarta.xml.soap-api</artifactId>
@@ -787,6 +825,12 @@
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
<version>2.3.2</version>
<exclusions>
<exclusion>
<groupId>jakarta.activation</groupId>
<artifactId>jakarta.activation-api</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>

View File

@@ -1,13 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.ws</groupId>
<artifactId>spring-ws</artifactId>
<version>3.1.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>spring-ws-core</artifactId>
@@ -118,6 +119,10 @@
<groupId>org.codehaus.woodstox</groupId>
<artifactId>wstx-asl</artifactId>
</exclusion>
<exclusion>
<groupId>com.fasterxml.woodstox</groupId>
<artifactId>woodstox-core</artifactId>
</exclusion>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
@@ -125,7 +130,14 @@
</exclusions>
</dependency>
<!--// WSDL-->
<dependency>
<groupId>org.apache.ws.commons.axiom</groupId>
<artifactId>axiom-compat</artifactId>
<version>${axiom.version}</version>
<optional>true</optional>
</dependency>
<!--// WSDL-->
<dependency>
<groupId>wsdl4j</groupId>
<artifactId>wsdl4j</artifactId>
@@ -230,4 +242,20 @@
</profile>
</profiles>
</project>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>test-jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2005-2010 the original author or authors.
* Copyright 2005-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -25,15 +25,16 @@ import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPFactory;
/**
* Caching payload in Axiom.
* Caching payload in Axiom 1.2.
*
* @author Arjen Poutsma
* @author Greg Turnquist
* @since 1.5.2
*/
@SuppressWarnings("Since15")
class CachingPayload extends AbstractPayload {
class Axiom12CachingPayload extends AxiomAbstractPayload {
CachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
Axiom12CachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
super(axiomBody, axiomFactory);
}
@@ -48,5 +49,4 @@ class CachingPayload extends AbstractPayload {
public Result getResultInternal() {
return getAxiomBody().getSAXResult();
}
}

View File

@@ -35,17 +35,18 @@ import org.apache.axiom.soap.SOAPFactory;
import org.springframework.util.xml.StaxUtils;
/**
* Non-caching payload in Axiom.
* Non-caching payload in Axiom 1.2.
*
* @author Jim Cummings
* @author Arjen Poutsma
* @author Greg Turnquist
* @since 1.5.2
*/
class NonCachingPayload extends AbstractPayload {
class Axiom12NonCachingPayload extends AxiomAbstractPayload {
private static final int BUF_SIZE = 1024;
NonCachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
Axiom12NonCachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
super(axiomBody, axiomFactory);
}
@@ -77,7 +78,7 @@ class NonCachingPayload extends AbstractPayload {
try {
this.delegate = StAXUtils.createXMLStreamWriter(baos);
} catch (XMLStreamException ex) {
throw new AxiomSoapBodyException("Could not determine payload root element", ex);
throw new RuntimeException("Could not determine payload root element", ex);
}
}
@@ -286,6 +287,5 @@ class NonCachingPayload extends AbstractPayload {
public void writeProcessingInstruction(String target, String data) throws XMLStreamException {
delegate.writeProcessingInstruction(target, data);
}
}
}

View File

@@ -0,0 +1,66 @@
/*
* Copyright 2005-2022 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
import java.io.InputStream;
import javax.xml.stream.XMLInputFactory;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamReader;
import org.apache.axiom.attachments.Attachments;
import org.apache.axiom.om.impl.MTOMConstants;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPMessage;
import org.apache.axiom.soap.SOAPModelBuilder;
import org.apache.axiom.soap.impl.builder.MTOMStAXSOAPModelBuilder;
import org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder;
/**
* Utilities for building SOAP messages using Axiom 1.2.
*
* @author Greg Turnquist
* @since 3.1
*/
final class Axiom12Utils {
private Axiom12Utils() {
throw new RuntimeException("Utility class not meant to be instantiated.");
}
static SOAPMessage getSOAPMessage(XMLInputFactory inputFactory, InputStream inputStream, String charSetEncoding,
String namespace, SOAPFactory soapFactory) throws XMLStreamException {
XMLStreamReader reader = inputFactory.createXMLStreamReader(inputStream, charSetEncoding);
SOAPModelBuilder builder = new StAXSOAPModelBuilder(reader, soapFactory, namespace);
return builder.getSOAPMessage();
}
static SOAPMessage getSOAPMessage(String envelopeNamespace, Attachments attachments, SOAPFactory soapFactory,
XMLStreamReader reader) {
SOAPModelBuilder builder;
if (MTOMConstants.SWA_TYPE.equals(attachments.getAttachmentSpecType())
|| MTOMConstants.SWA_TYPE_12.equals(attachments.getAttachmentSpecType())) {
builder = new StAXSOAPModelBuilder(reader, soapFactory, envelopeNamespace);
} else if (MTOMConstants.MTOM_TYPE.equals(attachments.getAttachmentSpecType())) {
builder = new MTOMStAXSOAPModelBuilder(reader, attachments, envelopeNamespace);
} else {
throw new RuntimeException("Unknown attachment type: [" + attachments.getAttachmentSpecType() + "]");
}
return builder.getSOAPMessage();
}
}

View File

@@ -0,0 +1,51 @@
/*
* Copyright 2005-2022 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
import javax.xml.stream.XMLStreamReader;
import javax.xml.transform.Result;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.OMXMLStreamReaderConfiguration;
import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPFactory;
/**
* Caching payload in Axiom 1.4.
*
* @author Arjen Poutsma
* @author Greg Turnquist
* @since 3.1
*/
class Axiom14CachingPayload extends AxiomAbstractPayload {
Axiom14CachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
super(axiomBody, axiomFactory);
}
@Override
protected XMLStreamReader getStreamReader(OMElement payloadElement) {
OMXMLStreamReaderConfiguration config = new OMXMLStreamReaderConfiguration();
config.setPreserveNamespaceContext(true);
return payloadElement.getXMLStreamReader(true, config);
}
@Override
public Result getResultInternal() {
return getAxiomBody().getSAXResult();
}
}

View File

@@ -0,0 +1,296 @@
/*
* Copyright 2005-2014 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
import java.io.ByteArrayOutputStream;
import java.io.UnsupportedEncodingException;
import javax.xml.namespace.NamespaceContext;
import javax.xml.namespace.QName;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamReader;
import javax.xml.stream.XMLStreamWriter;
import javax.xml.transform.Result;
import org.apache.axiom.om.OMDataSource;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.OMNamespace;
import org.apache.axiom.om.ds.StringOMDataSource;
import org.apache.axiom.om.util.StAXUtils;
import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.util.xml.StaxUtils;
/**
* Non-caching payload in Axiom 1.4.
*
* @author Jim Cummings
* @author Arjen Poutsma
* @author Greg Turnquist
* @since 3.1
*/
class Axiom14NonCachingPayload extends AxiomAbstractPayload {
private static final int BUF_SIZE = 1024;
Axiom14NonCachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
super(axiomBody, axiomFactory);
}
@Override
public Result getResultInternal() {
return StaxUtils.createCustomStaxResult(new DelegatingStreamWriter());
}
@Override
protected XMLStreamReader getStreamReader(OMElement payloadElement) {
return payloadElement.getXMLStreamReaderWithoutCaching();
}
private class DelegatingStreamWriter implements XMLStreamWriter {
private final ByteArrayOutputStream baos = new ByteArrayOutputStream(BUF_SIZE);
private final XMLStreamWriter delegate;
private QName name;
private String encoding = "UTF-8";
private int elementDepth = 0;
private boolean payloadAdded = false;
private DelegatingStreamWriter() {
try {
this.delegate = StAXUtils.createXMLStreamWriter(baos);
} catch (XMLStreamException ex) {
throw new RuntimeException("Could not determine payload root element", ex);
}
}
@Override
public void writeStartDocument() throws XMLStreamException {
// ignored
}
@Override
public void writeStartDocument(String version) throws XMLStreamException {
// ignored
}
@Override
public void writeStartDocument(String encoding, String version) throws XMLStreamException {
this.encoding = encoding;
}
@Override
public void writeStartElement(String localName) throws XMLStreamException {
if (name == null) {
name = new QName(localName);
}
elementDepth++;
delegate.writeStartElement(localName);
}
@Override
public void writeStartElement(String namespaceURI, String localName) throws XMLStreamException {
if (name == null) {
name = new QName(namespaceURI, localName);
}
elementDepth++;
delegate.writeStartElement(namespaceURI, localName);
}
@Override
public void writeStartElement(String prefix, String localName, String namespaceURI) throws XMLStreamException {
if (name == null) {
name = new QName(namespaceURI, localName, prefix);
}
elementDepth++;
delegate.writeStartElement(prefix, localName, namespaceURI);
}
@Override
public void writeEndElement() throws XMLStreamException {
elementDepth--;
delegate.writeEndElement();
addPayload();
}
private void addPayload() throws XMLStreamException {
if (elementDepth <= 0 && !payloadAdded) {
delegate.flush();
if (baos.size() > 0) {
SOAPFactory axiomFactory = getAxiomFactory();
try {
OMDataSource dataSource = new StringOMDataSource(baos.toString(encoding));
OMNamespace namespace = axiomFactory.createOMNamespace(name.getNamespaceURI(), name.getPrefix());
OMElement payloadElement = axiomFactory.createOMElement(dataSource, name.getLocalPart(), namespace);
getAxiomBody().addChild(payloadElement);
} catch (UnsupportedEncodingException e) {
throw new RuntimeException(e);
}
payloadAdded = true;
}
}
}
@Override
public void writeEmptyElement(String localName) throws XMLStreamException {
if (name == null) {
name = new QName(localName);
}
delegate.writeEmptyElement(localName);
addPayload();
}
@Override
public void writeEmptyElement(String namespaceURI, String localName) throws XMLStreamException {
if (name == null) {
name = new QName(namespaceURI, localName);
}
delegate.writeEmptyElement(namespaceURI, localName);
addPayload();
}
@Override
public void writeEmptyElement(String prefix, String localName, String namespaceURI) throws XMLStreamException {
if (name == null) {
name = new QName(namespaceURI, localName, prefix);
}
delegate.writeEmptyElement(prefix, localName, namespaceURI);
addPayload();
}
@Override
public void writeEndDocument() throws XMLStreamException {
elementDepth = 0;
delegate.writeEndDocument();
addPayload();
}
// Delegation
@Override
public void close() throws XMLStreamException {
addPayload();
delegate.close();
}
@Override
public void flush() throws XMLStreamException {
delegate.flush();
}
@Override
public NamespaceContext getNamespaceContext() {
return delegate.getNamespaceContext();
}
@Override
public String getPrefix(String uri) throws XMLStreamException {
return delegate.getPrefix(uri);
}
@Override
public Object getProperty(String name) throws IllegalArgumentException {
return delegate.getProperty(name);
}
@Override
public void setDefaultNamespace(String uri) throws XMLStreamException {
delegate.setDefaultNamespace(uri);
}
@Override
public void setNamespaceContext(NamespaceContext context) throws XMLStreamException {
delegate.setNamespaceContext(context);
}
@Override
public void setPrefix(String prefix, String uri) throws XMLStreamException {
delegate.setPrefix(prefix, uri);
}
@Override
public void writeAttribute(String localName, String value) throws XMLStreamException {
delegate.writeAttribute(localName, value);
}
@Override
public void writeAttribute(String namespaceURI, String localName, String value) throws XMLStreamException {
delegate.writeAttribute(namespaceURI, localName, value);
}
@Override
public void writeAttribute(String prefix, String namespaceURI, String localName, String value)
throws XMLStreamException {
delegate.writeAttribute(prefix, namespaceURI, localName, value);
}
@Override
public void writeCData(String data) throws XMLStreamException {
delegate.writeCData(data);
}
@Override
public void writeCharacters(char[] text, int start, int len) throws XMLStreamException {
delegate.writeCharacters(text, start, len);
}
@Override
public void writeCharacters(String text) throws XMLStreamException {
delegate.writeCharacters(text);
}
@Override
public void writeComment(String data) throws XMLStreamException {
delegate.writeComment(data);
}
@Override
public void writeDefaultNamespace(String namespaceURI) throws XMLStreamException {
delegate.writeDefaultNamespace(namespaceURI);
}
@Override
public void writeDTD(String dtd) throws XMLStreamException {
delegate.writeDTD(dtd);
}
@Override
public void writeEntityRef(String name) throws XMLStreamException {
delegate.writeEntityRef(name);
}
@Override
public void writeNamespace(String prefix, String namespaceURI) throws XMLStreamException {
delegate.writeNamespace(prefix, namespaceURI);
}
@Override
public void writeProcessingInstruction(String target) throws XMLStreamException {
delegate.writeProcessingInstruction(target);
}
@Override
public void writeProcessingInstruction(String target, String data) throws XMLStreamException {
delegate.writeProcessingInstruction(target, data);
}
}
}

View File

@@ -0,0 +1,62 @@
/*
* Copyright 2005-2022 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
import java.io.InputStream;
import javax.xml.stream.XMLInputFactory;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamReader;
import org.apache.axiom.attachments.Attachments;
import org.apache.axiom.om.OMXMLBuilderFactory;
import org.apache.axiom.om.impl.MTOMConstants;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPMessage;
import org.apache.axiom.soap.SOAPModelBuilder;
/**
* Utilities for building SOAP messages using Axiom 1.4.
*
* @author Greg Turnquist
* @since 3.1
*/
final class Axiom14Utils {
private Axiom14Utils() {
throw new RuntimeException("Utility class not meant to be instantiated.");
}
static SOAPMessage getSOAPMessage(XMLInputFactory inputFactory, InputStream inputStream, String charSetEncoding,
SOAPFactory soapFactory) throws XMLStreamException {
XMLStreamReader reader = inputFactory.createXMLStreamReader(inputStream, charSetEncoding);
SOAPModelBuilder builder = OMXMLBuilderFactory.createStAXSOAPModelBuilder(soapFactory.getMetaFactory(), reader);
return builder.getSOAPMessage();
}
static SOAPMessage getSOAPMessage(Attachments attachments, SOAPFactory soapFactory, XMLStreamReader reader) {
SOAPModelBuilder builder;
if (MTOMConstants.SWA_TYPE.equals(attachments.getAttachmentSpecType())
|| MTOMConstants.SWA_TYPE_12.equals(attachments.getAttachmentSpecType())) {
builder = OMXMLBuilderFactory.createStAXSOAPModelBuilder(soapFactory.getMetaFactory(), reader);
} else if (MTOMConstants.MTOM_TYPE.equals(attachments.getAttachmentSpecType())) {
builder = OMXMLBuilderFactory.createSOAPModelBuilder(soapFactory.getMetaFactory(), attachments);
} else {
throw new RuntimeException("Unknown attachment type: [" + attachments.getAttachmentSpecType() + "]");
}
return builder.getSOAPMessage();
}
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2005-2010 the original author or authors.
* Copyright 2005-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -16,6 +16,8 @@
package org.springframework.ws.soap.axiom;
import java.util.Iterator;
import javax.xml.stream.XMLStreamReader;
import javax.xml.transform.Result;
import javax.xml.transform.Source;
@@ -26,21 +28,21 @@ import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.util.Assert;
import org.springframework.util.xml.StaxUtils;
import org.springframework.ws.soap.axiom.support.AxiomUtils;
/**
* Abstract base class for {@link Payload} implementations.
* Abstract base class for Axiom 1.4 {@link Payload} implementations.
*
* @author Arjen Poutsma
* @since 2.0
* @author Greg Turnquist
* @since 3.1
*/
abstract class AbstractPayload extends Payload {
abstract class AxiomAbstractPayload implements Payload {
private final SOAPBody axiomBody;
private final SOAPFactory axiomFactory;
protected AbstractPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
protected AxiomAbstractPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
Assert.notNull(axiomBody, "'axiomBody' must not be null");
Assert.notNull(axiomFactory, "'axiomFactory' must not be null");
this.axiomBody = axiomBody;
@@ -58,7 +60,7 @@ abstract class AbstractPayload extends Payload {
return null;
}
} catch (OMException ex) {
throw new AxiomSoapBodyException(ex);
throw new RuntimeException(ex);
}
}
@@ -66,7 +68,10 @@ abstract class AbstractPayload extends Payload {
@Override
public final Result getResult() {
AxiomUtils.removeContents(getAxiomBody());
for (Iterator<?> iterator = getAxiomBody().getChildren(); iterator.hasNext();) {
iterator.next();
iterator.remove();
}
return getResultInternal();
}
@@ -83,5 +88,4 @@ abstract class AbstractPayload extends Payload {
protected OMElement getPayloadElement() throws OMException {
return getAxiomBody().getFirstElement();
}
}

View File

@@ -0,0 +1,50 @@
/*
* Copyright 2005-2022 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
import static org.springframework.ws.soap.axiom.support.AxiomUtils.AXIOM14_IS_PRESENT;
import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPFactory;
/**
* Utility to create various {@link Payload}s for Axiom.
*
* @author Greg Turnquist
* @since 3.1
*/
final class AxiomPayloadUtils {
private AxiomPayloadUtils() {
throw new RuntimeException("Utility class not meant to be instantiated.");
}
static Payload createCachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
if (AXIOM14_IS_PRESENT()) {
return new Axiom14CachingPayload(axiomBody, axiomFactory);
} else {
return new Axiom12CachingPayload(axiomBody, axiomFactory);
}
}
static Payload createNonCachingPayload(SOAPBody axiomBody, SOAPFactory axiomFactory) {
if (AXIOM14_IS_PRESENT()) {
return new Axiom14NonCachingPayload(axiomBody, axiomFactory);
} else {
return new Axiom12NonCachingPayload(axiomBody, axiomFactory);
}
}
}

View File

@@ -22,13 +22,7 @@ import javax.xml.namespace.QName;
import org.apache.axiom.om.OMAttribute;
import org.apache.axiom.om.OMNamespace;
import org.apache.axiom.soap.SOAP11Constants;
import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPFault;
import org.apache.axiom.soap.SOAPFaultCode;
import org.apache.axiom.soap.SOAPFaultReason;
import org.apache.axiom.soap.SOAPProcessingException;
import org.apache.axiom.soap.*;
import org.springframework.util.Assert;
import org.springframework.util.StringUtils;
import org.springframework.ws.soap.axiom.support.AxiomUtils;

View File

@@ -47,7 +47,7 @@ class AxiomSoap11Header extends AxiomSoapHeader implements Soap11Header {
if (!ObjectUtils.isEmpty(actors)) {
rolePlayer = new RolePlayer() {
public List<?> getRoles() {
public List getRoles() {
return Arrays.asList(actors);
}

View File

@@ -20,15 +20,7 @@ import java.util.Locale;
import javax.xml.namespace.QName;
import org.apache.axiom.soap.SOAP12Constants;
import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPFault;
import org.apache.axiom.soap.SOAPFaultCode;
import org.apache.axiom.soap.SOAPFaultReason;
import org.apache.axiom.soap.SOAPFaultText;
import org.apache.axiom.soap.SOAPFaultValue;
import org.apache.axiom.soap.SOAPProcessingException;
import org.apache.axiom.soap.*;
import org.springframework.util.Assert;
import org.springframework.ws.soap.axiom.support.AxiomUtils;
import org.springframework.ws.soap.soap12.Soap12Body;

View File

@@ -24,15 +24,7 @@ import java.util.Locale;
import javax.xml.namespace.QName;
import org.apache.axiom.om.OMNamespace;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPFault;
import org.apache.axiom.soap.SOAPFaultCode;
import org.apache.axiom.soap.SOAPFaultNode;
import org.apache.axiom.soap.SOAPFaultReason;
import org.apache.axiom.soap.SOAPFaultSubCode;
import org.apache.axiom.soap.SOAPFaultText;
import org.apache.axiom.soap.SOAPFaultValue;
import org.apache.axiom.soap.SOAPProcessingException;
import org.apache.axiom.soap.*;
import org.springframework.util.StringUtils;
import org.springframework.ws.soap.axiom.support.AxiomUtils;
import org.springframework.ws.soap.soap12.Soap12Fault;

View File

@@ -25,11 +25,7 @@ import javax.xml.namespace.QName;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.OMException;
import org.apache.axiom.om.OMNamespace;
import org.apache.axiom.soap.RolePlayer;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPHeader;
import org.apache.axiom.soap.SOAPHeaderBlock;
import org.apache.axiom.soap.SOAPProcessingException;
import org.apache.axiom.soap.*;
import org.springframework.util.ObjectUtils;
import org.springframework.ws.soap.SoapHeaderElement;
import org.springframework.ws.soap.SoapHeaderException;
@@ -84,7 +80,7 @@ class AxiomSoap12Header extends AxiomSoapHeader implements Soap12Header {
if (!ObjectUtils.isEmpty(roles)) {
rolePlayer = new RolePlayer() {
public List<?> getRoles() {
public List getRoles() {
return Arrays.asList(roles);
}

View File

@@ -42,9 +42,9 @@ abstract class AxiomSoapBody extends AxiomSoapElement implements SoapBody {
protected AxiomSoapBody(SOAPBody axiomBody, SOAPFactory axiomFactory, boolean payloadCaching) {
super(axiomBody, axiomFactory);
if (payloadCaching) {
payload = new CachingPayload(axiomBody, axiomFactory);
payload = AxiomPayloadUtils.createCachingPayload(axiomBody, axiomFactory);
} else {
payload = new NonCachingPayload(axiomBody, axiomFactory);
payload = AxiomPayloadUtils.createNonCachingPayload(axiomBody, axiomFactory);
}
}

View File

@@ -17,12 +17,7 @@
package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMException;
import org.apache.axiom.soap.SOAP11Constants;
import org.apache.axiom.soap.SOAP12Constants;
import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPEnvelope;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPHeader;
import org.apache.axiom.soap.*;
import org.springframework.ws.soap.SoapBody;
import org.springframework.ws.soap.SoapEnvelope;
import org.springframework.ws.soap.SoapHeader;

View File

@@ -17,11 +17,7 @@
package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMException;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPFault;
import org.apache.axiom.soap.SOAPFaultDetail;
import org.apache.axiom.soap.SOAPFaultRole;
import org.apache.axiom.soap.SOAPProcessingException;
import org.apache.axiom.soap.*;
import org.springframework.ws.soap.SoapFault;
import org.springframework.ws.soap.SoapFaultDetail;

View File

@@ -16,12 +16,7 @@
package org.springframework.ws.soap.axiom;
import java.io.IOException;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.StringWriter;
import java.io.UnsupportedEncodingException;
import java.io.Writer;
import java.io.*;
import java.util.Iterator;
import javax.activation.DataHandler;
@@ -35,11 +30,7 @@ import org.apache.axiom.om.OMOutputFormat;
import org.apache.axiom.om.OMXMLBuilderFactory;
import org.apache.axiom.om.impl.MTOMConstants;
import org.apache.axiom.om.impl.OMMultipartWriter;
import org.apache.axiom.soap.SOAPBody;
import org.apache.axiom.soap.SOAPEnvelope;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPMessage;
import org.apache.axiom.soap.SOAPProcessingException;
import org.apache.axiom.soap.*;
import org.springframework.util.Assert;
import org.springframework.util.StringUtils;
import org.springframework.ws.mime.Attachment;

View File

@@ -29,16 +29,7 @@ import javax.xml.stream.XMLStreamReader;
import org.apache.axiom.attachments.Attachments;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.om.OMException;
import org.apache.axiom.om.impl.MTOMConstants;
import org.apache.axiom.soap.SOAP11Constants;
import org.apache.axiom.soap.SOAP11Version;
import org.apache.axiom.soap.SOAP12Constants;
import org.apache.axiom.soap.SOAP12Version;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPMessage;
import org.apache.axiom.soap.SOAPModelBuilder;
import org.apache.axiom.soap.impl.builder.MTOMStAXSOAPModelBuilder;
import org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder;
import org.apache.axiom.soap.*;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.InitializingBean;
@@ -48,6 +39,7 @@ import org.springframework.ws.server.endpoint.interceptor.PayloadLoggingIntercep
import org.springframework.ws.server.endpoint.mapping.PayloadRootAnnotationMethodEndpointMapping;
import org.springframework.ws.soap.SoapMessageFactory;
import org.springframework.ws.soap.SoapVersion;
import org.springframework.ws.soap.axiom.support.AxiomUtils;
import org.springframework.ws.soap.server.endpoint.interceptor.PayloadValidatingInterceptor;
import org.springframework.ws.soap.server.endpoint.mapping.SoapActionAnnotationMethodEndpointMapping;
import org.springframework.ws.soap.support.SoapUtils;
@@ -184,7 +176,7 @@ public class AxiomSoapMessageFactory implements SoapMessageFactory, Initializing
/**
* Sets whether internal entity references should be replaced with their replacement text and report them as
* characters.
*
*
* @see XMLInputFactory#IS_REPLACING_ENTITY_REFERENCES
*/
public void setReplacingEntityReferences(boolean replacingEntityReferences) {
@@ -193,7 +185,7 @@ public class AxiomSoapMessageFactory implements SoapMessageFactory, Initializing
/**
* Sets whether external parsed entities should be resolved.
*
*
* @see XMLInputFactory#IS_SUPPORTING_EXTERNAL_ENTITIES
*/
public void setSupportingExternalEntities(boolean supportingExternalEntities) {
@@ -268,10 +260,17 @@ public class AxiomSoapMessageFactory implements SoapMessageFactory, Initializing
/** Creates an AxiomSoapMessage without attachments. */
private AxiomSoapMessage createAxiomSoapMessage(InputStream inputStream, String contentType, String soapAction)
throws XMLStreamException {
XMLStreamReader reader = inputFactory.createXMLStreamReader(inputStream, getCharSetEncoding(contentType));
String envelopeNamespace = getSoapEnvelopeNamespace(contentType);
SOAPModelBuilder builder = new StAXSOAPModelBuilder(reader, soapFactory, envelopeNamespace);
SOAPMessage soapMessage = builder.getSOAPMessage();
SOAPMessage soapMessage;
if (AxiomUtils.AXIOM14_IS_PRESENT()) {
soapMessage = Axiom14Utils.getSOAPMessage(inputFactory, inputStream, getCharSetEncoding(contentType),
soapFactory);
} else {
soapMessage = Axiom12Utils.getSOAPMessage(inputFactory, inputStream, getCharSetEncoding(contentType),
getSoapEnvelopeNamespace(contentType), soapFactory);
}
return new AxiomSoapMessage(soapMessage, soapAction, payloadCaching, langAttributeOnSoap11FaultString);
}
@@ -283,19 +282,20 @@ public class AxiomSoapMessageFactory implements SoapMessageFactory, Initializing
attachmentCacheDir.getAbsolutePath(), Integer.toString(attachmentCacheThreshold));
XMLStreamReader reader = inputFactory.createXMLStreamReader(attachments.getRootPartInputStream(),
getCharSetEncoding(attachments.getRootPartContentType()));
SOAPModelBuilder builder;
String envelopeNamespace = getSoapEnvelopeNamespace(contentType);
if (MTOMConstants.SWA_TYPE.equals(attachments.getAttachmentSpecType())
|| MTOMConstants.SWA_TYPE_12.equals(attachments.getAttachmentSpecType())) {
builder = new StAXSOAPModelBuilder(reader, soapFactory, envelopeNamespace);
} else if (MTOMConstants.MTOM_TYPE.equals(attachments.getAttachmentSpecType())) {
builder = new MTOMStAXSOAPModelBuilder(reader, attachments, envelopeNamespace);
} else {
throw new AxiomSoapMessageCreationException(
"Unknown attachment type: [" + attachments.getAttachmentSpecType() + "]");
SOAPMessage soapMessage;
try {
if (AxiomUtils.AXIOM14_IS_PRESENT()) {
soapMessage = Axiom14Utils.getSOAPMessage(attachments, soapFactory, reader);
} else {
soapMessage = Axiom12Utils.getSOAPMessage(getSoapEnvelopeNamespace(contentType), attachments, soapFactory,
reader);
}
} catch (RuntimeException e) {
throw new AxiomSoapMessageCreationException(e.getMessage());
}
return new AxiomSoapMessage(builder.getSOAPMessage(), attachments, soapAction, payloadCaching,
langAttributeOnSoap11FaultString);
return new AxiomSoapMessage(soapMessage, attachments, soapAction, payloadCaching, langAttributeOnSoap11FaultString);
}
private String getSoapEnvelopeNamespace(String contentType) {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2005-2010 the original author or authors.
* Copyright 2005-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -13,31 +13,31 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ws.soap.axiom;
import javax.xml.transform.Result;
import javax.xml.transform.Source;
/**
* Defines the contract for payloads in Axiom.
* Defines the contract for payloads.
*
* @author Arjen Poutsma
* @author Greg Turnquist
* @since 1.5.2
*/
abstract class Payload {
interface Payload {
/**
* Returns the source of the payload.
*
* @return the source of the payload
*/
public abstract Source getSource();
Source getSource();
/**
* Returns the result of the payload.
*
* @return the result of the payload
*/
public abstract Result getResult();
Result getResult();
}

View File

@@ -25,12 +25,9 @@ import javax.xml.namespace.QName;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.transform.dom.DOMSource;
import org.apache.axiom.om.OMContainer;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.OMException;
import org.apache.axiom.om.OMNamespace;
import org.apache.axiom.om.OMXMLBuilderFactory;
import org.apache.axiom.om.*;
import org.apache.axiom.soap.SOAPEnvelope;
import org.springframework.util.ClassUtils;
import org.springframework.util.StringUtils;
import org.springframework.xml.DocumentBuilderFactoryUtils;
import org.w3c.dom.Document;
@@ -47,7 +44,18 @@ import org.w3c.dom.Element;
* @since 1.0.0
*/
@SuppressWarnings("Since15")
public abstract class AxiomUtils {
public final class AxiomUtils {
private AxiomUtils() {
throw new RuntimeException("Utility class not meant to be instantiated.");
}
/**
* Detect if Axiom 1.4 is on the classpath.
*/
public static boolean AXIOM14_IS_PRESENT() {
return ClassUtils.isPresent("org.apache.axiom.om.ds.StringOMDataSource", null);
}
/**
* Converts a {@code javax.xml.namespace.QName} to a {@code org.apache.axiom.om.OMNamespace}. A {@code OMElement} is
@@ -92,7 +100,9 @@ public abstract class AxiomUtils {
return StringUtils.parseLocaleString(language);
}
/** Removes the contents (i.e. children) of the container. */
/**
* Removes the contents (i.e. children) of the container.
*/
public static void removeContents(OMContainer container) {
for (Iterator<?> iterator = container.getChildren(); iterator.hasNext();) {
iterator.next();
@@ -136,5 +146,4 @@ public abstract class AxiomUtils {
public static SOAPEnvelope toEnvelope(Document document) {
return OMXMLBuilderFactory.createSOAPModelBuilder(new DOMSource(document)).getSOAPEnvelope();
}
}

View File

@@ -0,0 +1,14 @@
package org.springframework.ws.soap.axiom;
import org.junit.jupiter.api.Test;
import org.springframework.ws.soap.axiom.support.AxiomUtils;
import static org.assertj.core.api.Assertions.assertThat;
public class Axiom14DetectionTest {
@Test
void detectedAxiom14Correctly() {
assertThat(AxiomUtils.AXIOM14_IS_PRESENT()).isTrue();
}
}

View File

@@ -21,6 +21,8 @@ import org.apache.axiom.soap.SOAPFactory;
import org.junit.jupiter.api.Test;
import org.springframework.ws.soap.SoapBody;
import org.springframework.ws.soap.SoapVersion;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.axiom.AxiomSoapMessageFactory;
import org.springframework.ws.soap.soap11.AbstractSoap11BodyTestCase;
import org.springframework.xml.transform.StringSource;

View File

@@ -19,6 +19,7 @@ package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.ws.soap.SoapEnvelope;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.soap11.AbstractSoap11EnvelopeTestCase;
public class AxiomSoap11EnvelopeTest extends AbstractSoap11EnvelopeTestCase {

View File

@@ -19,6 +19,7 @@ package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.ws.soap.SoapHeader;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.soap11.AbstractSoap11HeaderTestCase;
public class AxiomSoap11HeaderTest extends AbstractSoap11HeaderTestCase {

View File

@@ -16,7 +16,8 @@
package org.springframework.ws.soap.axiom;
import static org.assertj.core.api.Assertions.*;
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.api.Assertions.fail;
import java.io.ByteArrayInputStream;
import java.io.InputStream;
@@ -28,6 +29,8 @@ import org.junit.jupiter.api.Test;
import org.springframework.ws.InvalidXmlException;
import org.springframework.ws.WebServiceMessage;
import org.springframework.ws.WebServiceMessageFactory;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.axiom.AxiomSoapMessageFactory;
import org.springframework.ws.soap.soap11.AbstractSoap11MessageFactoryTestCase;
import org.springframework.ws.transport.MockTransportInputStream;
import org.springframework.ws.transport.TransportInputStream;

View File

@@ -19,6 +19,7 @@ package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.ws.soap.SoapMessage;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.soap11.AbstractSoap11MessageTestCase;
public class AxiomSoap11MessageTest extends AbstractSoap11MessageTestCase {

View File

@@ -18,6 +18,8 @@ package org.springframework.ws.soap.axiom;
import org.springframework.ws.soap.SoapBody;
import org.springframework.ws.soap.SoapVersion;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.axiom.AxiomSoapMessageFactory;
import org.springframework.ws.soap.soap11.AbstractSoap11BodyTestCase;
public class AxiomSoap11NonCachingBodyTest extends AbstractSoap11BodyTestCase {

View File

@@ -16,7 +16,7 @@
package org.springframework.ws.soap.axiom;
import static org.assertj.core.api.Assertions.*;
import static org.assertj.core.api.Assertions.assertThat;
import org.apache.axiom.om.OMSourcedElement;
import org.springframework.ws.soap.SoapBody;

View File

@@ -21,6 +21,8 @@ import org.apache.axiom.soap.SOAPFactory;
import org.junit.jupiter.api.Test;
import org.springframework.ws.soap.SoapBody;
import org.springframework.ws.soap.SoapVersion;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.axiom.AxiomSoapMessageFactory;
import org.springframework.ws.soap.soap12.AbstractSoap12BodyTestCase;
import org.springframework.xml.transform.StringSource;

View File

@@ -19,6 +19,7 @@ package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.ws.soap.SoapEnvelope;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.soap12.AbstractSoap12EnvelopeTestCase;
public class AxiomSoap12EnvelopeTest extends AbstractSoap12EnvelopeTestCase {

View File

@@ -19,6 +19,7 @@ package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.ws.soap.SoapHeader;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.soap12.AbstractSoap12HeaderTestCase;
public class AxiomSoap12HeaderTest extends AbstractSoap12HeaderTestCase {

View File

@@ -19,6 +19,7 @@ package org.springframework.ws.soap.axiom;
import org.springframework.ws.InvalidXmlException;
import org.springframework.ws.WebServiceMessageFactory;
import org.springframework.ws.soap.SoapVersion;
import org.springframework.ws.soap.axiom.AxiomSoapMessageFactory;
import org.springframework.ws.soap.soap12.AbstractSoap12MessageFactoryTestCase;
public class AxiomSoap12MessageFactoryTest extends AbstractSoap12MessageFactoryTestCase {

View File

@@ -19,6 +19,7 @@ package org.springframework.ws.soap.axiom;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.soap.SOAPFactory;
import org.springframework.ws.soap.SoapMessage;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.soap12.AbstractSoap12MessageTestCase;
public class AxiomSoap12MessageTest extends AbstractSoap12MessageTestCase {

View File

@@ -18,6 +18,8 @@ package org.springframework.ws.soap.axiom;
import org.springframework.ws.soap.SoapBody;
import org.springframework.ws.soap.SoapVersion;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
import org.springframework.ws.soap.axiom.AxiomSoapMessageFactory;
import org.springframework.ws.soap.soap12.AbstractSoap12BodyTestCase;
public class AxiomSoap12NonCachingBodyTest extends AbstractSoap12BodyTestCase {

View File

@@ -16,7 +16,7 @@
package org.springframework.ws.soap.axiom;
import static org.assertj.core.api.Assertions.*;
import static org.assertj.core.api.Assertions.assertThat;
import org.apache.axiom.om.OMSourcedElement;
import org.springframework.ws.soap.SoapBody;

View File

@@ -16,7 +16,7 @@
package org.springframework.ws.soap.axiom;
import static org.assertj.core.api.Assertions.*;
import static org.assertj.core.api.Assertions.assertThat;
import java.io.StringReader;
@@ -27,6 +27,7 @@ import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.ws.soap.SoapFault;
import org.springframework.ws.soap.SoapFaultDetail;
import org.springframework.ws.soap.axiom.AxiomSoapMessage;
@SuppressWarnings("Since15")
public class AxiomSoapFaultDetailTest {

View File

@@ -16,7 +16,7 @@
package org.springframework.ws.soap.axiom;
import static org.xmlunit.assertj.XmlAssert.*;
import static org.xmlunit.assertj.XmlAssert.assertThat;
import java.io.StringWriter;
@@ -28,6 +28,8 @@ import org.apache.axiom.soap.SOAPFactory;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.util.xml.StaxUtils;
import org.springframework.ws.soap.axiom.AxiomPayloadUtils;
import org.springframework.ws.soap.axiom.Payload;
@SuppressWarnings("Since15")
public class NonCachingPayloadTest {
@@ -41,7 +43,7 @@ public class NonCachingPayloadTest {
SOAPFactory soapFactory = OMAbstractFactory.getSOAP11Factory();
body = soapFactory.createSOAPBody();
payload = new NonCachingPayload(body, soapFactory);
payload = AxiomPayloadUtils.createNonCachingPayload(body, soapFactory);
}
@Test

View File

@@ -16,20 +16,7 @@
package org.springframework.ws.soap.axiom.support;
import static org.assertj.core.api.Assertions.*;
import java.io.StringWriter;
import java.util.Locale;
import javax.xml.namespace.QName;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
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.OMXMLBuilderFactory;
import org.apache.axiom.om.*;
import org.apache.axiom.soap.SOAPEnvelope;
import org.apache.axiom.soap.SOAPMessage;
import org.apache.axiom.soap.SOAPModelBuilder;
@@ -38,11 +25,20 @@ import org.junit.jupiter.api.Test;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
import org.springframework.util.FileCopyUtils;
import org.springframework.ws.soap.axiom.support.AxiomUtils;
import org.springframework.xml.DocumentBuilderFactoryUtils;
import org.springframework.xml.sax.SaxUtils;
import org.w3c.dom.Document;
import org.xmlunit.assertj.XmlAssert;
import javax.xml.namespace.QName;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import java.io.StringWriter;
import java.util.Locale;
import static org.assertj.core.api.Assertions.assertThat;
public class AxiomUtilsTest {
private OMElement element;

View File

@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
@@ -163,6 +163,10 @@
<groupId>org.codehaus.woodstox</groupId>
<artifactId>woodstox-core-asl</artifactId>
</exclusion>
<exclusion>
<groupId>com.fasterxml.woodstox</groupId>
<artifactId>woodstox-core</artifactId>
</exclusion>
<exclusion>
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
@@ -224,8 +228,8 @@
<artifactId>wstx-asl</artifactId>
</exclusion>
<exclusion>
<groupId>org.codehaus.woodstox</groupId>
<artifactId>woodstox-core-asl</artifactId>
<groupId>com.fasterxml.woodstox</groupId>
<artifactId>woodstox-core</artifactId>
</exclusion>
<exclusion>
<groupId>commons-logging</groupId>
@@ -264,4 +268,4 @@
</profile>
</profiles>
</project>
</project>

20
spring-ws-tests/pom.xml Normal file
View File

@@ -0,0 +1,20 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.ws</groupId>
<artifactId>spring-ws</artifactId>
<version>3.1.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>spring-ws-tests</artifactId>
<packaging>pom</packaging>
<description>A collection of modules to test various scenarios with Spring WS</description>
<modules>
<module>spring-ws-axiom-1.2-tests</module>
</modules>
</project>

View File

@@ -0,0 +1,66 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.ws</groupId>
<artifactId>spring-ws-tests</artifactId>
<version>3.1.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>spring-ws-axiom-1.2-tests</artifactId>
<dependencies>
<dependency>
<groupId>org.springframework.ws</groupId>
<artifactId>spring-ws-core</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.ws</groupId>
<artifactId>spring-ws-core</artifactId>
<version>${project.parent.version}</version>
<type>test-jar</type>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.ws.commons.axiom</groupId>
<artifactId>axiom-api</artifactId>
<version>${axiom-1.2.version}</version>
<optional>true</optional>
<exclusions>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.ws.commons.axiom</groupId>
<artifactId>axiom-impl</artifactId>
<version>${axiom-1.2.version}</version>
<optional>true</optional>
<exclusions>
<exclusion>
<groupId>org.codehaus.woodstox</groupId>
<artifactId>wstx-asl</artifactId>
</exclusion>
<exclusion>
<groupId>com.fasterxml.woodstox</groupId>
<artifactId>woodstox-core</artifactId>
</exclusion>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
</project>

View File

@@ -0,0 +1,29 @@
/*
* Copyright 2005-2014 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
import static org.assertj.core.api.Assertions.assertThat;
import org.junit.jupiter.api.Test;
import org.springframework.ws.soap.axiom.support.AxiomUtils;
public class Axiom12DetectionTest {
@Test
void detectedAxiom12Correctly() {
assertThat(AxiomUtils.AXIOM14_IS_PRESENT()).isFalse();
}
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12NonCachingPayloadTest extends NonCachingPayloadTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2014 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap11BodyTest extends AxiomSoap11BodyTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap11EnvelopeTest extends AxiomSoap11EnvelopeTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap11HeaderTest extends AxiomSoap11HeaderTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2012 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap11MessageFactoryTest extends AxiomSoap11MessageFactoryTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap11MessageTest extends AxiomSoap11MessageTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2014 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap11NonCachingBodyTest extends AxiomSoap11NonCachingBodyTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2014 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap11NonCachingMessageTest extends AxiomSoap11NonCachingMessageTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2014 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap12BodyTest extends AxiomSoap12BodyTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap12EnvelopeTest extends AxiomSoap12EnvelopeTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap12HeaderTest extends AxiomSoap12HeaderTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2012 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap12MessageFactoryTest extends AxiomSoap12MessageFactoryTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap12MessageTest extends AxiomSoap12MessageTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2014 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap12NonCachingBodyTest extends AxiomSoap12NonCachingBodyTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12Soap12NonCachingMessageTest extends AxiomSoap12NonCachingMessageTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom;
public class Axiom12SoapFaultDetailTest extends AxiomSoapFaultDetailTest {
}

View File

@@ -0,0 +1,21 @@
/*
* Copyright 2005-2010 the original author or authors.
*
* Licensed 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.springframework.ws.soap.axiom.support;
public class Axiom12UtilsTest extends AxiomUtilsTest {
}

View File

@@ -0,0 +1,5 @@
<html>
<body>
Provides a core interface requires for any version of Axiom.
</body>
</html>

View File

@@ -16,7 +16,8 @@
package org.springframework.xml.xpath;
import static org.assertj.core.api.Assertions.*;
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
import java.io.IOException;
import java.io.InputStream;
@@ -35,8 +36,6 @@ import org.w3c.dom.Document;
import org.w3c.dom.Node;
import org.xml.sax.SAXException;
import com.sun.org.apache.xpath.internal.XPathProcessorException;
public abstract class AbstractXPathExpressionFactoryTestCase {
private Document noNamespacesDocument;