summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk
diff options
context:
space:
mode:
authorbdaniel <bdaniel@13f79535-47bb-0310-9956-ffa450edef68>2010-07-19 18:34:04 +0000
committerbdaniel <bdaniel@13f79535-47bb-0310-9956-ffa450edef68>2010-07-19 18:34:04 +0000
commita0d8a49fa968f508993af66c8b48dd375252d73c (patch)
treeb4f0d0bff690897f6e582871a7a4aca3a838dd37 /sca-java-2.x/trunk
parent50bba5ef0060f35c224e8df5155015e47e499726 (diff)
Inherit elements lower in the hierarchy first to ensure inheritance of mutually exclusive intents is handled correctly
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@965578 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r--sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/CompositePolicyBuilderImpl.java16
1 files changed, 10 insertions, 6 deletions
diff --git a/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/CompositePolicyBuilderImpl.java b/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/CompositePolicyBuilderImpl.java
index d8c5db6524..db26b4550a 100644
--- a/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/CompositePolicyBuilderImpl.java
+++ b/sca-java-2.x/trunk/modules/builder/src/main/java/org/apache/tuscany/sca/builder/impl/CompositePolicyBuilderImpl.java
@@ -108,11 +108,13 @@ public class CompositePolicyBuilderImpl extends ComponentPolicyBuilderImpl imple
inherit(ep, Intent.Type.interaction, true, componentService.getInterfaceContract().getInterface());
}
- // Inherit from composite/component/service
- inherit(ep, Intent.Type.interaction, true, composite, ep.getComponent(), ep.getService());
-
// Inherit from binding
inherit(ep, Intent.Type.interaction, true, ep.getBinding());
+
+ // Inherit from composite/component/service
+ inherit(ep, Intent.Type.interaction, true, ep.getService(), ep.getComponent(), composite );
+
+
// Replace profile intents with their required intents
// Replace unqualified intents if there is a qualified intent in the list
@@ -160,13 +162,15 @@ public class CompositePolicyBuilderImpl extends ComponentPolicyBuilderImpl imple
if (componentReference.getInterfaceContract() != null) {
inherit(epr, Intent.Type.interaction, true, componentReference.getInterfaceContract().getInterface());
}
-
- // Inherit from composite/component/reference
- inherit(epr, Intent.Type.interaction, true, composite, epr.getComponent(), epr.getReference());
// Inherit from binding
inherit(epr, Intent.Type.interaction, true, epr.getBinding());
+ // Inherit from composite/component/reference
+ inherit(epr, Intent.Type.interaction, true, epr.getReference(), epr.getComponent(), composite);
+
+
+
// Replace profile intents with their required intents
// Replace unqualified intents if there is a qualified intent in the list
// Replace qualifiable intents with the default qualified intent