public ReliableRequestSessionChannel( ChannelManagerBase factory, IReliableFactorySettings settings, IClientReliableChannelBinder binder, FaultHelper faultHelper, LateBoundChannelParameterCollection channelParameters, UniqueId inputID) : base(factory, binder.RemoteAddress, binder.Via, true) { this.settings = settings; this.binder = binder; this.session = new ClientReliableSession(this, settings, binder, faultHelper, inputID); this.session.PollingCallback = this.PollingCallback; this.session.UnblockChannelCloseCallback = this.UnblockClose; if (this.settings.ReliableMessagingVersion == ReliableMessagingVersion.WSReliableMessagingFebruary2005) { this.shutdownHandle = new InterruptibleWaitObject(false); } else { this.replyAckConsistencyGuard = new Guard(Int32.MaxValue); } this.binder.Faulted += OnBinderFaulted; this.binder.OnException += OnBinderException; this.channelParameters = channelParameters; channelParameters.SetChannel(this); }
public ClientReliableDuplexSessionChannel(ChannelManagerBase factory, IReliableFactorySettings settings, IReliableChannelBinder binder, FaultHelper faultHelper, LateBoundChannelParameterCollection channelParameters, UniqueId inputID) : base(factory, settings, binder) { this.clientSession = new DuplexClientReliableSession(this, settings, faultHelper, inputID); this.clientSession.PollingCallback = new ClientReliableSession.PollingHandler(this.PollingCallback); base.SetSession(this.clientSession); this.channelParameters = channelParameters; channelParameters.SetChannel(this); ((IClientReliableChannelBinder)binder).ConnectionLost += new EventHandler(this.OnConnectionLost); }
protected ReliableOutputSessionChannel(ChannelManagerBase factory, IReliableFactorySettings settings, IClientReliableChannelBinder binder, FaultHelper faultHelper, LateBoundChannelParameterCollection channelParameters) : base(factory) { this.settings = settings; this.binder = binder; this.session = new ClientReliableSession(this, settings, binder, faultHelper, null); this.session.PollingCallback = new ClientReliableSession.PollingHandler(this.PollingCallback); this.session.UnblockChannelCloseCallback = new ChannelReliableSession.UnblockChannelCloseHandler(this.UnblockClose); this.binder.Faulted += new BinderExceptionHandler(this.OnBinderFaulted); this.binder.OnException += new BinderExceptionHandler(this.OnBinderException); this.channelParameters = channelParameters; channelParameters.SetChannel(this); }