diff options
author | slaws <slaws@13f79535-47bb-0310-9956-ffa450edef68> | 2009-10-09 08:49:49 +0000 |
---|---|---|
committer | slaws <slaws@13f79535-47bb-0310-9956-ffa450edef68> | 2009-10-09 08:49:49 +0000 |
commit | 24e45a6f5fd47b94646276534f0377f1399ab3bb (patch) | |
tree | 67cac250d36c41fdcc5b0cd3829180468175ac8b /branches/sca-java-1.5.2/modules/interface-wsdl | |
parent | 2566ede2ea1a755bef9522e6162f54342ea6c552 (diff) |
TUSCANY-3283 generate unannotated beans into the namespace of the WSDL rather than an empty namespace
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@823459 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'branches/sca-java-1.5.2/modules/interface-wsdl')
2 files changed, 18 insertions, 0 deletions
diff --git a/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/WSDLDefinition.java b/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/WSDLDefinition.java index 039e75f437..60f8647960 100644 --- a/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/WSDLDefinition.java +++ b/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/WSDLDefinition.java @@ -137,4 +137,12 @@ public interface WSDLDefinition extends Base { * @param binding the WSDL binding */ void setBinding(Binding binding); + + /** + * Find the schema definition for the provided namespace + * + * @param namespace + * @return the schema definition relating to the provided namespace or null if not found + */ + XSDefinition getSchema(String namespace); } diff --git a/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/impl/WSDLDefinitionImpl.java b/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/impl/WSDLDefinitionImpl.java index 16e9cf43f3..7dd6b28665 100644 --- a/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/impl/WSDLDefinitionImpl.java +++ b/branches/sca-java-1.5.2/modules/interface-wsdl/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/impl/WSDLDefinitionImpl.java @@ -285,5 +285,15 @@ public class WSDLDefinitionImpl implements WSDLDefinition { public void setBinding(Binding binding) { this.binding = binding; } + + public XSDefinition getSchema(String namespace){ + for (XSDefinition xsDef : schemas){ + if (xsDef.getNamespace().equals(namespace)){ + return xsDef; + } + } + + return null; + } } |