public bool Prepare()
        {
            ScadaStorageProxy proxy = ScadaProxyFactory.Instance().ScadaStorageProxy();

            Console.WriteLine("Prepared? YES");
            var converter = new ScadaModelConverter();

            result = converter.Convert(proxy.GetCimModel());
            proxy.SetTransactionModel(result.Points);
            proxy.SetDomModel(result.Equipment.Values.ToList());
            return(true);
        }
Ejemplo n.º 2
0
        public async Task <bool> Prepare()
        {
            ServiceEventSource.Current.ServiceMessage(_context, "SCADA Transaction - Prepare!");
            ScadaStorageProxy proxy = new ScadaStorageProxy(ConfigurationReader.ReadValue(_context, "Settings", "Storage"));
            var converter           = new ScadaModelConverter();

            result = converter.Convert(await proxy.GetCimModel());
            await proxy.SetTransactionModel(result.Points);

            await proxy.SetDomModel(result.Equipment.Values.ToList());

            return(true);
        }