tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lrese...@apache.org
Subject svn commit: r829707 - /tuscany/java/sca/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/StructuralURIBuilderImpl.java
Date Mon, 26 Oct 2009 06:20:38 GMT
Author: lresende
Date: Mon Oct 26 06:20:38 2009
New Revision: 829707

URL: http://svn.apache.org/viewvc?rev=829707&view=rev
Log:
Allowing multiple bindings on a service

Modified:
    tuscany/java/sca/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/StructuralURIBuilderImpl.java

Modified: tuscany/java/sca/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/StructuralURIBuilderImpl.java
URL: http://svn.apache.org/viewvc/tuscany/java/sca/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/StructuralURIBuilderImpl.java?rev=829707&r1=829706&r2=829707&view=diff
==============================================================================
--- tuscany/java/sca/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/StructuralURIBuilderImpl.java
(original)
+++ tuscany/java/sca/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/StructuralURIBuilderImpl.java
Mon Oct 26 06:20:38 2009
@@ -71,6 +71,10 @@
             Binding existed = bindingMap.put(binding.getName(), binding);
             // Check that multiple bindings do not have the same name
             if (existed != null && existed != binding) {
+                if(binding.getClass() != existed.getClass()) {
+                    // Look for a binding of the same type
+                    continue;
+                }
                 if (contract instanceof Service) {
                     Monitor.error(monitor, this, Messages.ASSEMBLY_VALIDATION, "MultipleBindingsForService",
contract
                         .getName(), binding.getName());



Mime
View raw message