Beispiel #1
0
        protected override Variable Evaluate(ParsingScript script)
        {
            List <Variable> args = script.GetFunctionArgs();

            Utils.CheckArgs(args.Count, 3, m_name);

            string request  = Utils.GetSafeString(args, 0);
            string load     = Utils.GetSafeString(args, 1);
            string callBack = Utils.GetSafeString(args, 2);

            CustomFunction callbackFunction = ParserFunction.GetFunction(callBack, null) as CustomFunction;

            if (callbackFunction == null)
            {
                throw new ArgumentException("Error: Couldn't find function [" + callBack + "]");
            }

            ProxyClient.QueueRequest(callbackFunction, request, load);
            return(Variable.EmptyInstance);
        }