PropertyDescriptor.GetTypeFromName(String) 方法
定义
返回使用其名称的类型。Returns a type using its name.
protected:
Type ^ GetTypeFromName(System::String ^ typeName);
protected Type GetTypeFromName (string typeName);
member this.GetTypeFromName : string -> Type
Protected Function GetTypeFromName (typeName As String) As Type
参数
- typeName
- String
要检索的类型的程序集限定名称。The assembly-qualified name of the type to retrieve.
返回
与给定类型名称匹配的 Type,或者,如果未能找到匹配,则为 null。A Type that matches the given type name, or null if a match cannot be found.
注解
若要查找适当的类型,此方法首先检查此引用的类型的程序集 PropertyDescriptor 。To find the appropriate type, this method first checks the assembly of the type that this PropertyDescriptor references. 如果在程序集中找不到该类型,则调用 Type.GetType 。If it does not find the type in the assembly, it calls Type.GetType.