Example #1
0
        static void Main(string[] args)
        {
            try
            {
                var adapter = new MyLoggerFactoryAdapter(null) { OnMessage = AddLogMessage };
                LogManager.Adapter = adapter;

                _client = new CIAPI.Rpc.Client(RPC_URI);
                _client.LogIn(USERNAME, PASSWORD);

                for (int i = 0; i < 100; i++)
                {
                    ThreadPool.QueueUserWorkItem(s => EndlessTest());
                }

                Console.ReadKey();

                _client.LogOut();
                _client.Dispose();
            }
            catch (Exception exc)
            {
                Console.WriteLine(exc);
            }
        }
Example #2
0
        public static void DisConnectCIAPI()
        {
            StreamingClient.Disconnect();
            CIAPI_Client.LogOut();
            CIAPI_Client.Dispose();

            IsConnected = false;
        }