diff options
author | antelder <antelder@13f79535-47bb-0310-9956-ffa450edef68> | 2011-06-13 15:11:14 +0000 |
---|---|---|
committer | antelder <antelder@13f79535-47bb-0310-9956-ffa450edef68> | 2011-06-13 15:11:14 +0000 |
commit | a7b5ef23de1d3dd4aac8ed2ea6c1b6f725e2335a (patch) | |
tree | 1f878fa5da8aa8fcc5241bb1fd9a87ed1403af31 /sca-java-2.x/trunk/modules/builder | |
parent | 1c1806e9f77ed5fa75958092c0fef4ed044b3757 (diff) |
Enable setting a default base uri thats used if a specific base is not set but a default value is
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1135131 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/modules/builder')
-rw-r--r-- | sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/BindingURIBuilderImpl.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/BindingURIBuilderImpl.java b/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/BindingURIBuilderImpl.java index 4c5bca204b..bf89781eb4 100644 --- a/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/BindingURIBuilderImpl.java +++ b/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/BindingURIBuilderImpl.java @@ -48,6 +48,8 @@ import org.apache.tuscany.sca.monitor.Monitor; */ public class BindingURIBuilderImpl implements CompositeBuilder { + private static final QName DEFAULT = new QName("default"); + public BindingURIBuilderImpl(ExtensionPointRegistry registry) { } @@ -228,6 +230,11 @@ public class BindingURIBuilderImpl implements CompositeBuilder { List<String> uris = defaultBindings.get(binding.getType()); if (uris != null && uris.size() > 0) { baseURI = new URI(addSlashToPath(uris.get(0))); + } else { + uris = defaultBindings.get(DEFAULT); + if (uris != null && uris.size() > 0) { + baseURI = new URI(addSlashToPath(uris.get(0))); + } } } } |