TypeBuilder.GetProperties(BindingFlags) 方法

定義

依指定傳回這個類型所宣告或繼承的所有公用和非公用屬性。

public:
 override cli::array <System::Reflection::PropertyInfo ^> ^ GetProperties(System::Reflection::BindingFlags bindingAttr);
public override System.Reflection.PropertyInfo[] GetProperties (System.Reflection.BindingFlags bindingAttr);
override this.GetProperties : System.Reflection.BindingFlags -> System.Reflection.PropertyInfo[]
Public Overrides Function GetProperties (bindingAttr As BindingFlags) As PropertyInfo()

參數

bindingAttr
BindingFlags

這個引動過程屬性。 必須是來自 BindingFlags 的位元旗標:InvokeMethodNonPublic 等。

傳回

傳回 PropertyInfo 物件的陣列,如果使用了 nonPublic,則會代表這個類型上定義的公用和非公用屬性;否則只會傳回公用屬性。

例外狀況

不會為不完整的類型實作此方法。

備註

使用 或 Assembly.GetTypeType.GetType 取型別,並使用所擷取類型的反映。

適用於