コード例 #1
0
ファイル: TestTcpGateway.cs プロジェクト: radtek/_Proxy
 private static int Main2(string[] args)
 {
     tcpGateway = new TcpGateway();
     ParseCommandLineArgs(args);
     tcpGateway.logger = new Logger(Console.Out, logLevel);
     tcpGateway.Open();
     Console.WriteLine("Gateway started, press Enter to close.");
     Console.ReadLine();
     tcpGateway.Close();
     return(0);
 }
コード例 #2
0
 public static void Start()
 {
     tcpGateways = new ArrayList();
     foreach (GatewayConfig c in gatewayConfigs)
     {
         TcpGateway tcpGateway = new TcpGateway();
         tcpGateway.portNo1 = c.portNo1;
         tcpGateway.portNo2 = c.portNo2;
         tcpGateway.logger  = logger;
         tcpGateway.Open();
         tcpGateways.Add(tcpGateway);
     }
 }