Example #1
0
        public bool Bind(string functionName, XmlRpcFunc callback)
        {
            lock (gate)
            {
                if (functions.ContainsKey(functionName))
                {
                    return(false);
                }

                var method = new XmlRpcServerMethod(server, functionName, callback);
                functions.Add(functionName, method);
                server.AddMethod(method);
            }

            return(true);
        }
Example #2
0
        public bool Bind(string functionName, XmlRpcFunc callback)
        {
            //lock( functionsGate )
            //{
            if (functions.ContainsKey(functionName))
            {
                return(false);
            }

            var method = new XmlRpcServerMethod(server, functionName, callback);

            functions[functionName] = method;
            server.AddMethod(method);
            //    }
            return(true);
        }