Example #1
0
		public Expression Parse(string expression, Func<string, Expression> identifierHandler)
		{
			if (expression == null)
				throw new ArgumentNullException(nameof(expression));
			if (identifierHandler == null)
				throw new ArgumentNullException(nameof(identifierHandler));

			var tokenizer = new CExpressionTokenizer();
			var symbols = tokenizer.Tokenize(expression);

			return Parse(symbols, identifierHandler);
		}
Example #2
0
        public Expression Parse(string expression, Func <string, Expression> identifierHandler)
        {
            if (expression == null)
            {
                throw new ArgumentNullException(nameof(expression));
            }
            if (identifierHandler == null)
            {
                throw new ArgumentNullException(nameof(identifierHandler));
            }

            var tokenizer = new CExpressionTokenizer();
            var symbols   = tokenizer.Tokenize(expression);

            return(Parse(symbols, identifierHandler));
        }