//Выбрать ряды для генерации public IEnumerable <SubRows> SelectRows(TablsList dataTabls, SubRows parentRow) { IEnumerable <SubRows> rows = dataTabls.Tabls[_tablName].SubList; rows = _condition == null ? rows : rows.Where(row => _condition.Generate(row).Boolean); return(ChildNode == null ? rows : ChildNode.SelectRows(rows)); }
//Выбрать ряды для генерации, узел запроса public IEnumerable <SubRows> SelectRows(IEnumerable <SubRows> parentRows) { var rows = parentRows.SelectMany(row => Condition == null ? row.SubList : row.SubList.Where(r => Condition.Generate(r).Boolean)); return(ChildNode == null ? rows : ChildNode.SelectRows(rows)); }
//Выбрать ряды для генерации, главный узел выражения подтаблицы public IEnumerable <SubRows> SelectRows(TablsList dataTabls, SubRows parentRow) { IEnumerable <SubRows> rows = Condition == null ? parentRow.SubList : parentRow.SubList.Where(row => Condition.Generate(row).Boolean); return(ChildNode == null ? rows : ChildNode.SelectRows(rows)); }