diff options
Diffstat (limited to '')
3 files changed, 26 insertions, 20 deletions
diff --git a/branches/sca-java-1.3/itest/wsdl/src/main/resources/wsdl/Hello.xsd b/branches/sca-java-1.3/itest/wsdl/src/main/resources/wsdl/Hello.xsd new file mode 100644 index 0000000000..4fc5b10e7c --- /dev/null +++ b/branches/sca-java-1.3/itest/wsdl/src/main/resources/wsdl/Hello.xsd @@ -0,0 +1,20 @@ + + <schema elementFormDefault="qualified" xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema"> + + <element name="getGreetings"> + <complexType> + <sequence> + <element name="name" type="xsd:string"/> + </sequence> + </complexType> + </element> + + <element name="getGreetingsResponse"> + <complexType> + <sequence> + <element name="getGreetingsReturn" type="xsd:string"/> + </sequence> + </complexType> + </element> + + </schema> diff --git a/branches/sca-java-1.3/itest/wsdl/src/main/resources/wsdl/helloworld.wsdl b/branches/sca-java-1.3/itest/wsdl/src/main/resources/wsdl/helloworld.wsdl index 3921dec72d..1966acc957 100644 --- a/branches/sca-java-1.3/itest/wsdl/src/main/resources/wsdl/helloworld.wsdl +++ b/branches/sca-java-1.3/itest/wsdl/src/main/resources/wsdl/helloworld.wsdl @@ -21,24 +21,8 @@ name="helloworld"> <wsdl:types> - <schema elementFormDefault="qualified" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema"> - - <element name="getGreetings"> - <complexType> - <sequence> - <element name="name" type="xsd:string"/> - </sequence> - </complexType> - </element> - - <element name="getGreetingsResponse"> - <complexType> - <sequence> - <element name="getGreetingsReturn" type="xsd:string"/> - </sequence> - </complexType> - </element> - + <schema xmlns="http://www.w3.org/2001/XMLSchema"> + <import namespace="http://helloworld" schemaLocation="Hello.xsd"/> </schema> </wsdl:types> diff --git a/branches/sca-java-1.3/modules/binding-ws-axis2/src/main/java/org/apache/tuscany/sca/binding/ws/axis2/Axis2ServiceProvider.java b/branches/sca-java-1.3/modules/binding-ws-axis2/src/main/java/org/apache/tuscany/sca/binding/ws/axis2/Axis2ServiceProvider.java index 832e1a0cca..263b96d20f 100644 --- a/branches/sca-java-1.3/modules/binding-ws-axis2/src/main/java/org/apache/tuscany/sca/binding/ws/axis2/Axis2ServiceProvider.java +++ b/branches/sca-java-1.3/modules/binding-ws-axis2/src/main/java/org/apache/tuscany/sca/binding/ws/axis2/Axis2ServiceProvider.java @@ -520,8 +520,10 @@ public class Axis2ServiceProvider { private void addSchemas(WSDLDefinition wsdlDef, AxisService axisService) { for (XSDefinition xsDef : wsdlDef.getXmlSchemas()) { - axisService.addSchema(xsDef.getSchema()); - updateSchemaRefs(xsDef.getSchema(), axisService.getName()); + if (xsDef.getSchema() != null) { + axisService.addSchema(xsDef.getSchema()); + updateSchemaRefs(xsDef.getSchema(), axisService.getName()); + } } for (WSDLDefinition impDef : wsdlDef.getImportedDefinitions()) { addSchemas(impDef, axisService); |