示例#1
0
        public GeneratorParser(ExpressionParserFactory <T> expressionParserFactory)
        {
            if (expressionParserFactory == null)
            {
                throw new ArgumentException("expressionParser cannot be null");
            }

            ModuleParser = new ModuleParser <T>(expressionParserFactory);
            _ruleParser  = new RuleParser <T>(ModuleParser, expressionParserFactory);
        }
示例#2
0
 public RuleParser(ModuleParser <T> moduleParser, ExpressionParserFactory <T> expressionParserFactory)
 {
     _moduleParser            = moduleParser ?? throw new ParserException("moduleParser cannot be null");
     _expressionParserFactory = expressionParserFactory ??
                                throw new ArgumentException("expressionParserFactory cannot be null");
 }