Пример #1
0
        public void Do()
        {
            var equipmentList = EquipmentProvider.LoadData();

            var scenarioList = ScenarioBuilder.BuildScenarios(equipmentList);

            foreach (var scenario in scenarioList)
            {
                scenario.Calculate();
            }

            ReportsExporter.ExportReports(scenarioList);
        }
Пример #2
0
        static void Main(string[] args)
        {
            //	var services = new ServiceCollection();

            //RegisterServices(services);
            var reportProvider    = new MassReportProvider();
            var reportExporter    = new ConsoleReportExporter();
            var equipmentProvider = new DummyEquipmentProvider();
            var scenarioBuilder   = new ScenarioBuilder();
            var reportsExporter   = new ReportsExporter(new[] { reportProvider }, reportExporter);

            var calculator = new Calculator(equipmentProvider, scenarioBuilder, reportsExporter);

            calculator.Do();
        }