Пример #1
0
        public void BuildOutputChannelFactory()
        {
            PeerTransportBindingElement be =
                new PeerTransportBindingElement();

            be.Security.Mode = SecurityMode.None;
            CustomBinding binding = new CustomBinding(
                new HandlerTransportBindingElement(null));
            BindingContext ctx = new BindingContext(
                binding, new BindingParameterCollection());

            be.BuildChannelFactory <IOutputChannel> (ctx);
        }
		public void BuildRequestChannelFactory ()
		{
			// IRequestChannel is invalid
			PeerTransportBindingElement be =
				new PeerTransportBindingElement ();
			be.Security.Mode = SecurityMode.None;
			CustomBinding binding = new CustomBinding (
				new HandlerTransportBindingElement (null));
			BindingContext ctx = new BindingContext (
				binding, new BindingParameterCollection ());

			var f = be.BuildChannelFactory<IRequestChannel> (ctx);
			Assert.IsNotNull (f.GetProperty<IOnlineStatus> (), "#1");
			Assert.IsNotNull (f.GetProperty<PeerNode> (), "#2");
		}
Пример #3
0
        public void BuildRequestChannelFactory()
        {
            // IRequestChannel is invalid
            PeerTransportBindingElement be =
                new PeerTransportBindingElement();

            be.Security.Mode = SecurityMode.None;
            CustomBinding binding = new CustomBinding(
                new HandlerTransportBindingElement(null));
            BindingContext ctx = new BindingContext(
                binding, new BindingParameterCollection());

            var f = be.BuildChannelFactory <IRequestChannel> (ctx);

            Assert.IsNotNull(f.GetProperty <IOnlineStatus> (), "#1");
            Assert.IsNotNull(f.GetProperty <PeerNode> (), "#2");
        }
		public void BuildOutputChannelFactory ()
		{
			PeerTransportBindingElement be =
				new PeerTransportBindingElement ();
			be.Security.Mode = SecurityMode.None;
			CustomBinding binding = new CustomBinding (
				new HandlerTransportBindingElement (null));
			BindingContext ctx = new BindingContext (
				binding, new BindingParameterCollection ());
			be.BuildChannelFactory<IOutputChannel> (ctx);
		}