/// <summary> /// 通道已重新连接事件参数 /// </summary> /// <param name="contract">契约信息</param> public ChannelDisconnectedEventArgs(ContractInfo contract) { if (contract == null) { throw new ArgumentNullException("contract"); } ContractInfo = contract; }
/// <summary> /// 通道连接异常事件参数 /// </summary> /// <param name="contract">契约信息</param> public ChannelExceptionRaisedEventArgs(ContractInfo contract) { if (contract == null) { throw new ArgumentNullException("contract"); } ContractInfo = contract; }
private int _retryConnectCount = 0; // the count of retrying to connect the channel #endregion #region Constructors /// <summary> /// 单向通道管理器 /// </summary> /// <param name="contract">服务契约描述</param> public ProxyChannelManager(ContractInfo contract) { if (contract == null) { throw new ArgumentNullException("contract"); } _contract = contract; }
/// <summary> /// 回调通道管理器,对应双向回调服务中的回调契约 /// </summary> /// <param name="callbackInstanceContext">回调契约实例上下文</param> /// <param name="contract">回调契约描述</param> public CallbackChannelManager(TContract callbackInstanceContext, ContractInfo contract) { if (callbackInstanceContext == null) { throw new ArgumentNullException("callbackInstanceContext"); } if (contract == null) { throw new ArgumentNullException("contract"); } _callback = callbackInstanceContext; _contract = contract; }
/// <summary> /// 通道已重新连接事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="reason">连接断开原因</param> public ChannelDisconnectedEventArgs(ContractInfo contract, string reason) : this(contract) { Reason = reason; }
/// <summary> /// 通道连接异常事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="exception">连接异常</param> public ChannelExceptionRaisedEventArgs(ContractInfo contract, Exception exception) : this(contract) { Exception = exception; }
/// <summary> /// 通道已重新连接事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="reason">连接断开原因</param> public ChannelDisconnectedEventArgs(ContractInfo contract, string reason) : this(contract) { Reason = reason; }
/// <summary> /// 双向通道管理器 /// </summary> /// <param name="instanceContext">服务契约实例上下文</param> /// <param name="contract">服务契约描述</param> public ProxyDuplexChannelManager(InstanceContext instanceContext, ContractInfo contract) : base(contract) { this._instanceContext = instanceContext; }
/// <summary> /// 通道连接已建立事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="channel">连接通道</param> /// <param name="exception">连接异常</param> public ChannelEstablishedEventArgs(ContractInfo contract, object channel, Exception exception) : this(contract, channel) { Exception = exception; }
/// <summary> /// 通道连接已建立事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="channel">连接通道</param> public ChannelEstablishedEventArgs(ContractInfo contract, object channel) : this(contract) { Channel = channel; }
/// <summary> /// 通道连接已建立事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="channel">连接通道</param> /// <param name="exception">连接异常</param> public ChannelEstablishedEventArgs(ContractInfo contract, object channel, Exception exception) : this(contract, channel) { Exception = exception; }
/// <summary> /// 通道连接已建立事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="channel">连接通道</param> public ChannelEstablishedEventArgs(ContractInfo contract, object channel) : this(contract) { Channel = channel; }
/// <summary> /// 通道连接异常事件参数 /// </summary> /// <param name="contract">契约信息</param> /// <param name="exception">连接异常</param> public ChannelExceptionRaisedEventArgs(ContractInfo contract, Exception exception) : this(contract) { Exception = exception; }