Esempio n. 1
0
 public override void Run()
 {
     if (ConnectArguments.IsServer())
     {
         _server = new TcpChannelServer(ConnectArguments.CreateNetTcpAddress());
         _server.StartServer();
     }
     else
     {
         _clients  = new DuplexChannelManager(ConnectArguments.ConnectionLimit,
                                                 ConnectArguments.MessageRate,
                                                 new NetTcpBinding() { Security = { Mode = SecurityMode.None } },
                                                 ConnectArguments.CreateNetTcpAddress());
         _clients.Start();
     }
 }
Esempio n. 2
0
 public override void Run()
 {
     if (ConnectArguments.IsServer())
     {
         _server = new TcpChannelServer(ConnectArguments.CreateNetTcpAddress());
         _server.StartServer();
     }
     else
     {
         _clients = new DuplexChannelManager(ConnectArguments.ConnectionLimit,
                                             ConnectArguments.MessageRate,
                                             new NetTcpBinding()
         {
             Security = { Mode = SecurityMode.None }
         },
                                             ConnectArguments.CreateNetTcpAddress());
         _clients.Start();
     }
 }