/// <summary> /// 执行 /// </summary> /// <param name="key">键</param> /// <param name="parames">参数数组</param> /// <returns>返回值</returns> public virtual object Invoke(string key, params object[] parames) { if (dicCaches.ContainsKey(key)) { return(Get(key).Invoke(null, parames)); } else { string fullName = null; if (dicClasses == null) { var tempDicClasses = readerConfig.Reader(); if (tempDicClasses != null) { lock (syncDicCaches) { dicClasses = tempDicClasses; } fullName = dicClasses[key]; } } else { fullName = dicClasses[key]; } MethodInfo method; var re = ReflectUtil.InvokeStaticMethod(fullName, out method, parames); Set(key, method); return(re); } }