Exemplo n.º 1
0
        public IList<String> Parse(string input, bool showOutput)
        {
            Context.Parser = this;
            Context.Object = null;
            Context.IndirectObject = null;
            
            parserResults = new List<string>();

            Library L = new Library();
            bool wasLit = L.IsLit();

            var userInput = new UserInput();
            var inputResult = userInput.Parse(input);
            isAll = inputResult.IsAll;

            if (inputResult.HasError)
            {
                parserResults.Add(inputResult.Error);
            }
            else
            {
                HandleInputResult(inputResult);
            }

            if (!wasLit && L.IsLit())
                L.Look(true);

            return GetResults(showOutput);
        }