Example #1
0
        public ExpressionEvaluator(bool compose, IOutputProcessor outputProcessor, ParsingProcessor tokenParser = null,
                                   IEnumerable <ITokenProcessor <IParseResult> > tokenProcessors = null)
        {
            _resultTokens             = new Stack <IParseResult>();
            _tokenProcessorDictionary = new Dictionary <Type, ITokenProcessor <IParseResult> >();
            OutputProcessor           = outputProcessor;

            if (compose)
            {
                PerformComposition();
            }
            else
            {
                TokenParser     = tokenParser;
                TokenProcessors = tokenProcessors;
            }
        }
Example #2
0
 public void Initialize()
 {
     _tokenParser = InitializationHelpers.InitializeTokenParser();
 }