public static BatchFile Load(TextReader reader) { var statements = new List <CommandStatement>(); string line; while ((line = reader.ReadLine()) != null) { if (!string.IsNullOrWhiteSpace(line)) { statements.Add(StatementParser.Parse(line)); } } return(new BatchFile(statements)); }
public BatchInstance(BatchFile batch, string arguments) { this.Batch = batch; this.arguments = StatementParser.ParseArguments(arguments); }