cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cschnei...@apache.org
Subject svn commit: r1095647 - /cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainInterceptor.java
Date Thu, 21 Apr 2011 10:39:47 GMT
Author: cschneider
Date: Thu Apr 21 10:39:46 2011
New Revision: 1095647

URL: http://svn.apache.org/viewvc?rev=1095647&view=rev
Log:
Refactored to improve readability

Modified:
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainInterceptor.java

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainInterceptor.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainInterceptor.java?rev=1095647&r1=1095646&r2=1095647&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainInterceptor.java
(original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainInterceptor.java
Thu Apr 21 10:39:46 2011
@@ -56,22 +56,22 @@ public class OutgoingChainInterceptor ex
 
     public void handleMessage(Message message) {
         Exchange ex = message.getExchange();
-        BindingOperationInfo bin = ex.get(BindingOperationInfo.class);
-        if (null != bin && null != bin.getOperationInfo() && bin.getOperationInfo().isOneWay())
{
+        BindingOperationInfo binding = ex.get(BindingOperationInfo.class);
+        if (null != binding && null != binding.getOperationInfo() && binding.getOperationInfo().isOneWay())
{
             closeInput(message);
             return;
         }
         Message out = ex.getOutMessage();
         if (out != null) {
             getBackChannelConduit(message);
-            if (bin != null) {
-                out.put(MessageInfo.class, bin.getOperationInfo().getOutput());
-                out.put(BindingMessageInfo.class, bin.getOutput());
+            if (binding != null) {
+                out.put(MessageInfo.class, binding.getOperationInfo().getOutput());
+                out.put(BindingMessageInfo.class, binding.getOutput());
             }
             
             InterceptorChain outChain = out.getInterceptorChain();
             if (outChain == null) {
-                outChain = getChain(ex);
+                outChain = OutgoingChainInterceptor.getChain(ex, chainCache);
                 out.setInterceptorChain(outChain);
             }
             outChain.doIntercept(out);
@@ -164,7 +164,8 @@ public class OutgoingChainInterceptor ex
             chain.add(((InterceptorProvider)m.getDestination()).getOutInterceptors());
         }
     }
-    private PhaseInterceptorChain getChain(Exchange ex) {
+    
+    private static PhaseInterceptorChain getChain(Exchange ex, PhaseChainCache chainCache)
{
         Bus bus = ex.get(Bus.class);
         Binding binding = ex.get(Binding.class);
         



Mime
View raw message