Esempio n. 1
0
 public ModuleParser(ExpressionParserFactory <T> expressionParserFactory)
 {
     _expressionParserFactory = expressionParserFactory ??
                                throw new ParserException("expressionParser cannot be null");
     _knownModules = new Dictionary <string, int>();
     _nextModuleId = 0;
 }
Esempio n. 2
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);
        }
Esempio n. 3
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");
 }