public List <string> Process(List <string> inputTexts) { var queryTexts = inputTexts.Where(x => x.Trim().EndsWith("?")).ToList(); var intergalacticWordsTexts = inputTexts.Except(queryTexts).ToList(); var inputStore = new InputStore(numberFormatCalculator, symbolValues); inputStore.Store(intergalacticWordsTexts); var queryInterpreter = new QueryInterpreter(numberFormatCalculator, symbolValues); return(queryInterpreter.Interpret(queryTexts)); }
public override void Initialize(Scene scene) { this.inputStore = this.world.GetGlobalResource <InputStore>(); var scenario = scene.Map.Scenario; this.executor = new InterpretingScriptExecutor(scenario); this.engine = new ScriptEngine(scene, this.executor, this.audioSystem, this.cameraSystem, this.actorSystem, this.animationSystem); this.executor.Initialize(this.engine); this.stopwatch = new Stopwatch(); this.stopwatch.Start(); scene.RegisterMetricSource(this.executor); base.Initialize(scene); }
public override void Initialize(Scene scene) { this.renderList = this.world.GetGlobalResource <RenderListStore>(); this.inputStore = this.world.GetGlobalResource <InputStore>(); }