2010-05-28 Atsushi Enomoto <atsushi@ximian.com>
[mono.git] / mcs / class / System.ServiceModel / System.ServiceModel.Dispatcher / ReplyHandler.cs
1 /*
2 using System;
3 using System.Collections.Generic;
4 using System.Text;
5 using System.ServiceModel.Channels;
6 using System.ServiceModel;
7
8 namespace System.ServiceModel.Dispatcher
9 {
10         internal class ReplyHandler : BaseRequestProcessorHandler
11         {
12                 IDuplexChannel duplex;
13
14                 public ReplyHandler (IChannel channel)
15                 {
16                         duplex = channel as IDuplexChannel;
17                 }
18
19                 protected override bool ProcessRequest (MessageProcessingContext mrc)
20                 {
21                         // if IsOneWay then no need to handle reply
22                         if (mrc.Operation.IsOneWay)
23                                 return false;
24
25                         if (duplex != null)
26                                 mrc.Reply (duplex, true);
27                         else
28                                 mrc.Reply (true);
29                         return false;
30                 }
31         }
32 }
33 */