TypeBuilder.GetEvents Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns the events defined by the current TypeBuilder.
Overloads
GetEvents() |
Returns the public events declared or inherited by this type. |
GetEvents(BindingFlags) |
Returns the public and non-public events that are declared by this type. |
GetEvents()
- Source:
- TypeBuilder.cs
Returns the public events declared or inherited by this type.
public:
override cli::array <System::Reflection::EventInfo ^> ^ GetEvents();
public override System.Reflection.EventInfo[] GetEvents ();
override this.GetEvents : unit -> System.Reflection.EventInfo[]
Public Overrides Function GetEvents () As EventInfo()
Returns
Returns an array of EventInfo objects representing the public events declared or inherited by this type. An empty array is returned if there are no public events.
Exceptions
This method is not implemented for incomplete types.
Remarks
Retrieve the type using GetType or GetType and use reflection on the retrieved type.
Applies to
GetEvents(BindingFlags)
- Source:
- TypeBuilder.cs
Returns the public and non-public events that are declared by this type.
public:
override cli::array <System::Reflection::EventInfo ^> ^ GetEvents(System::Reflection::BindingFlags bindingAttr);
public override System.Reflection.EventInfo[] GetEvents (System.Reflection.BindingFlags bindingAttr);
override this.GetEvents : System.Reflection.BindingFlags -> System.Reflection.EventInfo[]
Public Overrides Function GetEvents (bindingAttr As BindingFlags) As EventInfo()
Parameters
- bindingAttr
- BindingFlags
A bitwise combination of BindingFlags values that limits the search.
Returns
Returns an array of EventInfo objects representing the events declared or inherited by this type that match the specified binding flags. An empty array is returned if there are no matching events.
Exceptions
This method is not implemented for incomplete types.
Remarks
Retrieve the type using Type.GetType or Assembly.GetType and use reflection on the retrieved type.
Applies to
Σχόλια
https://aka.ms/ContentUserFeedback.
Σύντομα διαθέσιμα: Καθ' όλη τη διάρκεια του 2024 θα καταργήσουμε σταδιακά τα ζητήματα GitHub ως μηχανισμό ανάδρασης για το περιεχόμενο και θα το αντικαταστήσουμε με ένα νέο σύστημα ανάδρασης. Για περισσότερες πληροφορίες, ανατρέξτε στο θέμα:Υποβολή και προβολή σχολίων για