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
This commit is contained in:
parent
1c1806e9f7
commit
a7b5ef23de
1 changed files with 7 additions and 0 deletions
|
@ -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)));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue