Редагувати

Поділитися через


ICustomTypeDescriptor.GetEvents Method

Definition

Returns the events for this instance of a component.

Overloads

GetEvents()

Returns the events for this instance of a component.

GetEvents(Attribute[])

Returns the events for this instance of a component using the specified attribute array as a filter.

GetEvents()

Returns the events for this instance of a component.

public:
 System::ComponentModel::EventDescriptorCollection ^ GetEvents();
public System.ComponentModel.EventDescriptorCollection GetEvents ();
abstract member GetEvents : unit -> System.ComponentModel.EventDescriptorCollection
Public Function GetEvents () As EventDescriptorCollection

Returns

An EventDescriptorCollection that represents the events for this component instance.

Remarks

The events for this instance can differ from the set of events that the class provides. For example, if the component is site-based, the site can add or remove additional events.

Implementors can return EventDescriptorCollection.Empty if no properties are specified. This method should never return null.

See also

Applies to

GetEvents(Attribute[])

Returns the events for this instance of a component using the specified attribute array as a filter.

public:
 System::ComponentModel::EventDescriptorCollection ^ GetEvents(cli::array <Attribute ^> ^ attributes);
public System.ComponentModel.EventDescriptorCollection GetEvents (Attribute[] attributes);
public System.ComponentModel.EventDescriptorCollection GetEvents (Attribute[]? attributes);
abstract member GetEvents : Attribute[] -> System.ComponentModel.EventDescriptorCollection
Public Function GetEvents (attributes As Attribute()) As EventDescriptorCollection

Parameters

attributes
Attribute[]

An array of type Attribute that is used as a filter.

Returns

An EventDescriptorCollection that represents the filtered events for this component instance.

Remarks

The events for this instance can differ from the set of events that the class provides. For example, if the component is site-based, the site can add or remove additional events.

If an Attribute is specified in the attributes array and the event does not have an instance of the class for that attribute, the returned array includes the event if the Attribute is the default event.

See also

Applies to