Example #1
0
        /// <summary>
        /// Entry point into console application.
        /// </summary>
        static void Main3()
        {
            dContext context = new dContext();

            // Usually a tree
            ArrayList list = new ArrayList();

            // Populate 'abstract syntax tree'
            list.Add(new TerminalExpression());
            list.Add(new NonterminalExpression());
            list.Add(new TerminalExpression());
            list.Add(new TerminalExpression());

            // Interpret
            foreach (AbstractExpression exp in list)
            {
                exp.Interpret(context);
            }

            // Wait for user
            Console.ReadKey();
        }
Example #2
0
 public BaseRepository(dContext context, IErrorHandler errorHandler)
 {
     _context      = context;
     _entities     = _context.Set <T>();
     _errorHandler = errorHandler;
 }
Example #3
0
 public override void Interpret(dContext context)
 {
     Console.WriteLine("Called Nonterminal.Interpret()");
 }
Example #4
0
 public abstract void Interpret(dContext context);