Evaluate() public méthode

public Evaluate ( ) : object
Résultat object
Exemple #1
0
        public void CreateAndEvaluateDelayedCall()
        {
            IFunction function = this.MakeFunction("f(X) -> X+1.");
            Context context = new Context();
            var arguments = new object[] { 1 };

            DelayedCall dcall = new DelayedCall(function, context, arguments);

            Assert.IsNotNull(dcall.Function);
            Assert.AreSame(function, dcall.Function);
            Assert.AreSame(context, dcall.Context);
            Assert.AreSame(arguments, dcall.Arguments);

            Assert.AreEqual(2, dcall.Evaluate());
        }