Exemplo n.º 1
0
        public DefaultPatWorkflow(string appDirectory)
        {
            _modulesService = new ModulesService(Path.Combine(appDirectory, "Modules"));
            _optionsService = new OptionsService(Path.Combine(appDirectory, "options.bin"));
            _volumeService  = new VolumeService();

            DimensionedValue.DimensionService = new DimensionService(_modulesService.GetModules <IDimensionModule>());

            _topHorizonDataSourceSelector = new ModuleSelector <IDataSourceModule>(_modulesService.GetModules <IDataSourceModule>(), _optionsService);
            _baseHorizonModifierSelector  = new ModuleSelector <ISourceModifierModule>(_modulesService.GetModules <ISourceModifierModule>(), _optionsService);
            _triangulationModuleSelector  = new ModuleSelector <ITriangulationModule>(_modulesService.GetModules <ITriangulationModule>(), _optionsService);
            _fluidContactModifierSelector = new ModuleSelector <ITriangulationModifierModule>(_modulesService.GetModules <ITriangulationModifierModule>(), _optionsService);
            _resultDimensionSelector      = new ModuleSelector <IDimensionModule>(_modulesService.GetModules <IDimensionModule>().Where(m => m.Type == DimensionType.Cubic), _optionsService);

            _resultDimensionSelector.PropertyChanged += ResultDimensionSelectorOnPropertyChanged;
        }
Exemplo n.º 2
0
 public Initializer()
 {
     _globalOptions  = new GlobalOptions();
     _optionsService = new TestOptionsService();
     _modulesService = new TestModulesService();
     _timerService   = new TimerService();
     _globalServices = new GlobalServices(_optionsService, _modulesService, _timerService);
     _globalContext  = new GlobalContext(_globalServices);
     _device         = (TestDevice)_modulesService.GetModules <IDeviceFactory>().First().GetDevices().First();
     _layoutContext  = new LayoutContext(_device, _globalContext, (layout) => {}, () => {}, () => { return(null); }, () => null);
 }