/// <summary>根据名称获取类型</summary> /// <param name="typeName">类型名</param> /// <param name="isLoadAssembly">是否从未加载程序集中获取类型。使用仅反射的方法检查目标类型,如果存在,则进行常规加载</param> /// <returns></returns> public virtual Type GetType(String typeName, Boolean isLoadAssembly) { //var type = Type.GetType(typeName); //if (type != null) return type; return(AssemblyX.GetType(typeName, isLoadAssembly)); }
/// <summary>根据名称获取类型</summary> /// <param name="typeName">类型名</param> /// <param name="isLoadAssembly">是否从未加载程序集中获取类型。使用仅反射的方法检查目标类型,如果存在,则进行常规加载</param> /// <returns></returns> public virtual Type GetType(String typeName, Boolean isLoadAssembly) { #if !__CORE__ return(AssemblyX.GetType(typeName, isLoadAssembly)); #else return(Type.GetType(typeName)); #endif }
/// <summary>根据名称获取类型</summary> /// <param name="typeName">类型名</param> /// <param name="isLoadAssembly">是否从未加载程序集中获取类型。使用仅反射的方法检查目标类型,如果存在,则进行常规加载</param> /// <returns></returns> public virtual Type GetType(String typeName, Boolean isLoadAssembly) => AssemblyX.GetType(typeName, isLoadAssembly);
/// <summary>根据名称获取类型</summary> /// <param name="typeName">类型名</param> /// <param name="isLoadAssembly">是否从未加载程序集中获取类型。使用仅反射的方法检查目标类型,如果存在,则进行常规加载</param> /// <returns></returns> public virtual Type GetType(String typeName, Boolean isLoadAssembly) { return(AssemblyX.GetType(typeName, isLoadAssembly)); }