Exemplo n.º 1
0
        public void Start()
        {
            _managementPort.Connect();
            _managementPort.RegisterReceiveMessageEvent(_packetForwarder.ConfigureFromManagementSystem);
            _managementPort.StartReceiving();

            foreach (string clientPortAlias in _configuration.ClientPortAliases)
            {
                _clientPorts.Add(clientPortAlias, _clientPortFactory.GetPort(clientPortAlias));
                _clientPorts[clientPortAlias].Connect();
                _clientPorts[clientPortAlias].RegisterReceiveMessageEvent(_packetForwarder.ForwardPacket);
                _clientPorts[clientPortAlias].StartReceiving();
            }

            _packetForwarder.SetClientPorts(_clientPorts);

            ManualResetEvent allDone = new ManualResetEvent(false);

            allDone.WaitOne();
        }
Exemplo n.º 2
0
 public void Start()
 {
     _clientPort = _clientPortFactory.GetPort(_configuration.ClientPortAlias);
     _clientPort.ConnectToCableCloud();
     _clientPort.StartReceiving();
 }