protected ContextProtocol(ContextExchangeMechanism contextExchangeMechanism)
 {
     if (!ContextExchangeMechanismHelper.IsDefined(contextExchangeMechanism))
     {
         throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("contextExchangeMechanism"));
     }
     this.contextExchangeMechanism = contextExchangeMechanism;
 }
 public static bool IsDefined(ContextExchangeMechanism value)
 {
     if (value != ContextExchangeMechanism.ContextSoapHeader)
     {
         return (value == ContextExchangeMechanism.HttpCookie);
     }
     return true;
 }
 public ClientContextProtocol(ContextExchangeMechanism contextExchangeMechanism, System.Uri uri, IChannel owner, System.Uri callbackAddress, bool contextManagementEnabled) : base(contextExchangeMechanism)
 {
     if (contextExchangeMechanism == ContextExchangeMechanism.HttpCookie)
     {
         this.cookieContainer = new CookieContainer();
     }
     this.context = ContextMessageProperty.Empty;
     this.contextManagementEnabled = contextManagementEnabled;
     this.owner = owner;
     this.thisLock = new object();
     this.uri = uri;
     this.callbackAddress = callbackAddress;
 }
 public static bool IsDefined(ContextExchangeMechanism value)
 {
     return value == ContextExchangeMechanism.ContextSoapHeader ||
         value == ContextExchangeMechanism.HttpCookie;
 }
 public ServiceContextProtocol(ContextExchangeMechanism contextExchangeMechanism)
     : base(contextExchangeMechanism)
 {
     // empty
 }
예제 #6
0
 public ContextInputSessionChannel(ChannelManagerBase channelManager, IInputSessionChannel innerChannel, ContextExchangeMechanism contextExchangeMechanism) : base(channelManager, innerChannel, contextExchangeMechanism)
 {
 }