private Parser(ICommandResultInternal element, char[] charArray, bool cleancls) { this.currentCommand2 = element; this.charArray = charArray; this.cleancls = cleancls; }
private bool TryCommand(ref int pos) { int savedpos = pos; StringBuilder sb = new StringBuilder(50); do { sb.Append(charArray[savedpos]); savedpos++; } while (ParseValue(savedpos) == Token.AlphaNumeric); if (ParseValue(savedpos) == Token.WhiteSpace || ParseValue(savedpos) == Token.End) { ICommandResultInternal command = (from obj in currentCommand2.Commands from obj2 in obj.Token.SplitInternal() where sb.ToString() == obj2 select obj).SingleOrDefault(); if(command != null) { command.IsSet=true; currentCommand2 = command; pos = savedpos; return true; } } return false; }
//*****new Stuff***** internal Parser(ICommandResultInternal element, string commandLine, bool cleancls) : this(element, commandLine.ToCharArray(), cleancls) { }