From 2f18ce4790ab8a5e80fe371ef0107ea7e49c23c9 Mon Sep 17 00:00:00 2001 From: slaws Date: Thu, 17 Jun 2010 11:58:16 +0000 Subject: improve variable name git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@955562 13f79535-47bb-0310-9956-ffa450edef68 --- .../runtime/impl/EndpointReferenceBinderImpl.java | 28 +++++++++++----------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'sca-java-2.x/trunk') diff --git a/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/runtime/impl/EndpointReferenceBinderImpl.java b/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/runtime/impl/EndpointReferenceBinderImpl.java index 177221586b..62d7750fe1 100644 --- a/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/runtime/impl/EndpointReferenceBinderImpl.java +++ b/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/runtime/impl/EndpointReferenceBinderImpl.java @@ -363,13 +363,13 @@ public class EndpointReferenceBinderImpl implements EndpointReferenceBinder { // find the first callback endpoint that matches a callback endpoint reference // at the service - RuntimeEndpoint matchedEndpoint = null; + RuntimeEndpoint callbackEndpoint = null; match: for ( EndpointReference callbackEndpointReference : endpointReference.getTargetEndpoint().getCallbackEndpointReferences()){ for (Endpoint endpoint : callbackService.getEndpoints()){ if (haveMatchingPolicy(callbackEndpointReference, endpoint, matchAudit) && haveMatchingInterfaceContracts(callbackEndpointReference, endpoint, matchAudit)){ - matchedEndpoint = (RuntimeEndpoint)endpoint; + callbackEndpoint = (RuntimeEndpoint)endpoint; break match; } } @@ -381,13 +381,13 @@ public class EndpointReferenceBinderImpl implements EndpointReferenceBinder { // callback that is different from the forward binding. Waiting for feedback form OASIS // before doing more drastic surgery to fix this corner case as there are other things // wrong with the default case, such as what to do about policy - if (matchedEndpoint == null || - (matchedEndpoint.getBinding().getType().equals(SCABinding.TYPE) && + if (callbackEndpoint == null || + (callbackEndpoint.getBinding().getType().equals(SCABinding.TYPE) && !endpointReference.getBinding().getType().equals(SCABinding.TYPE))){ // no endpoint in place so we need to create one - matchedEndpoint = (RuntimeEndpoint)assemblyFactory.createEndpoint(); - matchedEndpoint.setComponent(endpointReference.getComponent()); - matchedEndpoint.setService(callbackService); + callbackEndpoint = (RuntimeEndpoint)assemblyFactory.createEndpoint(); + callbackEndpoint.setComponent(endpointReference.getComponent()); + callbackEndpoint.setService(callbackService); Binding forwardBinding = endpointReference.getBinding(); Binding callbackBinding = null; @@ -411,25 +411,25 @@ public class EndpointReferenceBinderImpl implements EndpointReferenceBinder { } } - matchedEndpoint.setBinding(callbackBinding); + callbackEndpoint.setBinding(callbackBinding); callbackService.getBindings().add(callbackBinding); - matchedEndpoint.setUnresolved(false); - callbackService.getEndpoints().add(matchedEndpoint); + callbackEndpoint.setUnresolved(false); + callbackService.getEndpoints().add(callbackEndpoint); // build it - build(matchedEndpoint); + build(callbackEndpoint); // activate it compositeActivator.activate(((RuntimeEndpointReferenceImpl)endpointReference).getCompositeContext(), - matchedEndpoint); + callbackEndpoint); // start it compositeActivator.start(((RuntimeEndpointReferenceImpl)endpointReference).getCompositeContext(), - matchedEndpoint); + callbackEndpoint); } - endpointReference.setCallbackEndpoint(matchedEndpoint); + endpointReference.setCallbackEndpoint(callbackEndpoint); } private void build(Endpoint endpoint) { -- cgit v1.2.3