Example #1
0
        //Разбор выражения GenRule таблицы и подтаблицы
        private ITablStruct CheckRule(GenKeeper keeper, TablsList tabls, string formula)
        {
            keeper.Errors.Clear();
            var parsing = new RuleParsing(keeper, "поле", formula);

            if (parsing.ResultTree == null)
            {
                return(null);
            }
            return(((NodeRTabl)parsing.ResultTree).Check(tabls, null));
        }
Example #2
0
        //Выбрать ряды по условию генерации таблицы, возвращает ряды и, возможно, также структуру
        private SubRows[] SelectRowsS(GenKeeper keeper, TablsList tabls, string formula)
        {
            keeper.Errors.Clear();
            var parsing = new RuleParsing(keeper, "поле", formula);

            if (parsing.ResultTree == null)
            {
                return(null);
            }
            var node = (NodeRTabl)parsing.ResultTree;

            node.Check(tabls, null);
            return(node.SelectRows(tabls, null).ToArray());
        }
Example #3
0
        private IEnumerable <SubRows> SelectRowsStruct(GenKeeper keeper, TablsList tabls, string formula, out ITablStruct tstruct)
        {
            tstruct = null;
            keeper.Errors.Clear();
            var parsing = new RuleParsing(keeper, "поле", formula);

            if (parsing.ResultTree == null)
            {
                return(null);
            }
            var node = (NodeRTabl)parsing.ResultTree;

            tstruct = node.Check(tabls, null);
            return(node.SelectRows(tabls, null));
        }