コード例 #1
0
        public void Run()
        {
            var serverUri = new Uri(string.Format("net.tcp://localhost:{0}/OrderService", port));
            var wcfMessageService = new WcfMessageService(messageReceiver);

            host = new ServiceHost(wcfMessageService, serverUri);
            host.AddServiceEndpoint(typeof (IMessageService), new NetTcpBinding(), "");
            host.Open();
        }
コード例 #2
0
        public void Run()
        {
            var serverUri         = new Uri(string.Format("net.tcp://localhost:{0}/OrderService", port));
            var wcfMessageService = new WcfMessageService(messageReceiver);

            host = new ServiceHost(wcfMessageService, serverUri);
            host.AddServiceEndpoint(typeof(IMessageService), new NetTcpBinding(), "");
            host.Open();
        }