Exemple #1
0
        private void button1_Click(object sender, EventArgs e)
        {
            this.label1.Text = "Working...";
            this.label1.Update();

            // Okay the work goes here!
            int j = 0;

            for (int i = 0; i < 500000; i++)
            {
                status s = LogicExpressionEvaluator.Evaluate("1 && 1 || 0");
//                LogicExpressionEvaluator.Evaluate("1 && (0 || 1) && 5 > 2");
                j++;
                if (j == 1000)
                {
                    this.output.Text = (i + 1).ToString();
                    this.output.Update();
                    j = 0;
                }
            }
            this.label1.Text = "Done!";
            this.label1.Update();
        }
Exemple #2
0
 public void TestValidateExpression()
 {
     LogicExpressionEvaluator lee = new LogicExpressionEvaluator();
 }