TypeInfo.GetProperty 方法

定義

多載

GetProperty(String)

C#
public System.Reflection.PropertyInfo GetProperty(string name);

參數

name
String

傳回

適用於

.NET Core 1.1 和其他版本
產品 版本
.NET Core 1.0, Core 1.1
.NET Standard 1.5, 1.6

GetProperty(String, BindingFlags)

C#
public System.Reflection.PropertyInfo GetProperty(string name, System.Reflection.BindingFlags bindingAttr);

參數

name
String
bindingAttr
BindingFlags

傳回

適用於

.NET Core 1.1 和其他版本
產品 版本
.NET Core 1.0, Core 1.1
.NET Standard 1.5, 1.6

GetProperty(String, Type)

C#
public System.Reflection.PropertyInfo GetProperty(string name, Type returnType);

參數

name
String
returnType
Type

傳回

適用於

.NET Core 1.1 和其他版本
產品 版本
.NET Core 1.0, Core 1.1
.NET Standard 1.5, 1.6

GetProperty(String, Type[])

C#
public System.Reflection.PropertyInfo GetProperty(string name, Type[] types);

參數

name
String
types
Type[]

傳回

適用於

.NET Core 1.1 和其他版本
產品 版本
.NET Core 1.0, Core 1.1
.NET Standard 1.5, 1.6

GetProperty(String, Type, Type[])

C#
public System.Reflection.PropertyInfo GetProperty(string name, Type returnType, Type[] types);

參數

name
String
returnType
Type
types
Type[]

傳回

適用於

.NET Core 1.1 和其他版本
產品 版本
.NET Core 1.0, Core 1.1
.NET Standard 1.5, 1.6

GetProperty(String, Type, Type[], ParameterModifier[])

C#
public System.Reflection.PropertyInfo GetProperty(string name, Type returnType, Type[] types, System.Reflection.ParameterModifier[] modifiers);

參數

name
String
returnType
Type
types
Type[]
modifiers
ParameterModifier[]

傳回

適用於

.NET Core 1.1 和其他版本
產品 版本
.NET Core 1.0, Core 1.1
.NET Standard 1.5, 1.6