FindFunction() публичный Метод

Finds the function instance with the specified name.
public FindFunction ( String name ) : IFunction
name String /// The symbolic name to retrieve. ///
Результат IFunction
Пример #1
0
        /// <summary>
        /// Finds the function instance with the specified name.
        /// </summary>
        /// <param name="name">
        /// The symbolic name to retrieve.
        /// </param>
        /// <returns>The instance of the function's class.</returns>
        public IFunction FindFunction(String name)
        {
            if (_functions.ContainsKey(name))
            {
                return(_functions[name]);
            }

            if (_parent != null)
            {
                return(_parent.FindFunction(name));
            }

            return(null);
        }
Пример #2
0
        /// <summary>
        /// Finds the function instance with the specified name.
        /// </summary>
        /// <param name="name">
        /// The symbolic name to retrieve.
        /// </param>
        /// <returns>The instance of the function's class.</returns>
        public IFunction FindFunction(string name)
        {
            var lname = name.ToLower();

            if (functions.ContainsKey(lname))
            {
                return(functions[lname]);
            }

            if (parent != null)
            {
                return(parent.FindFunction(name));
            }

            return(null);
        }