protected ContextProtocol(System.ServiceModel.Channels.ContextExchangeMechanism contextExchangeMechanism) { if (!ContextExchangeMechanismHelper.IsDefined(contextExchangeMechanism)) { throw System.ServiceModel.DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("contextExchangeMechanism")); } this.contextExchangeMechanism = contextExchangeMechanism; }
public ContextChannelFactory(BindingContext context, ContextExchangeMechanism contextExchangeMechanism, Uri callbackAddress, bool contextManagementEnabled) : base((context == null) ? null : context.Binding, (context == null) ? null : context.BuildInnerChannelFactory <TChannel>()) { if (!ContextExchangeMechanismHelper.IsDefined(contextExchangeMechanism)) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("contextExchangeMechanism")); } this.contextExchangeMechanism = contextExchangeMechanism; this.callbackAddress = callbackAddress; this.contextManagementEnabled = contextManagementEnabled; }
public ContextChannelListener(BindingContext context, ContextExchangeMechanism contextExchangeMechanism) : base((context == null) ? null : context.Binding, (context == null) ? null : context.BuildInnerChannelListener <TChannel>()) { if (context == null) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("context"); } if (!ContextExchangeMechanismHelper.IsDefined(contextExchangeMechanism)) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("contextExchangeMechanism")); } this.contextExchangeMechanism = contextExchangeMechanism; this.listenBaseAddress = context.ListenUriBaseAddress; }