Beispiel #1
0
        private static System.ServiceModel.Channels.Binding BuildBinding(BindingTypeEnum BindingType)
        {
            switch (BindingType)
            {
            case BindingTypeEnum.BasicHttp:
                return(new BasicHttpBinding());

            case BindingTypeEnum.NetTcp:
                NetTcpBinding binding = new NetTcpBinding(SecurityMode.None);
                binding.MaxReceivedMessageSize = int.MaxValue;
                return(binding);

            default:
                throw new NotImplementedException();
            }
        }
Beispiel #2
0
 public ServiceBindingManager(Uri BaseAddress, BindingTypeEnum BindingType)
 {
     this._BaseAddress = BaseAddress;
     this._BindingType = BindingType;
 }