public GrammarStructure ToStructure(FixtureLibrary library) { Cell[] cells = InnerGrammar.GetCells() .Where(x => x.IsTestVariable(library.Finder)) .Select(c => c.ToInputCell()).ToArray(); return(new Table(LabelName, LeafName(), cells)); }
public override IList <Cell> GetCells() { var keys = DisplayParser.GetKeys(Template); return(_inner.GetCells().Where(cell => { if (keys.Contains(cell.Key)) { return true; } if (_defaults.ContainsKey(cell.Key)) { return false; } return !cell.HasDefault(); }).ToList()); }
public static Cell FindCell(this IGrammarWithCells grammar, string key) { return(grammar.GetCells().FirstOrDefault(x => x.Key == key)); }