RuntimeReflectionExtensions.GetRuntimeEvents(Type) RuntimeReflectionExtensions.GetRuntimeEvents(Type) RuntimeReflectionExtensions.GetRuntimeEvents(Type) Method

定義

擷取集合,表示指定的型別所定義的所有事件。Retrieves a collection that represents all the events defined on a specified type.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Collections::Generic::IEnumerable<System::Reflection::EventInfo ^> ^ GetRuntimeEvents(Type ^ type);
public static System.Collections.Generic.IEnumerable<System.Reflection.EventInfo> GetRuntimeEvents (this Type type);
static member GetRuntimeEvents : Type -> seq<System.Reflection.EventInfo>

參數

type
Type Type Type

包含事件的型別。The type that contains the events.

傳回

所指定型別的事件集合。A collection of events for the specified type.

例外狀況

備註

這個方法會傳回在指定的型別,包括繼承、 非公用執行個體和靜態事件上定義的所有事件。This method returns all events defined on the specified type, including inherited, non-public, instance, and static events.

適用於

另請參閱