Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

EventPattern<TEventArgs> Class

Encapsulates sender and event arguments for a .NET event.


Namespace:  System.Reactive
Assembly:  System.Reactive (in System.Reactive.dll)
public class EventPattern<TEventArgs> : IEquatable<EventPattern<TEventArgs>>
where TEventArgs : EventArgs

Type Parameters


The EventPattern<TEventArgs> type exposes the following members.

Public methodEventPattern<TEventArgs>Initialize a new instance of the EventPattern<TEventArgs> type.
Public propertyEventArgsRepresents event arguments for a .NET event.
Public propertySenderRepresents event sender information for a .NET event.
Public methodEquals(Object)Compares this type with the specified object. (Overrides Object.Equals(Object).)
Public methodEquals(EventPattern<TEventArgs>)Compares this type with the specified object.
Protected methodFinalize (Inherited from Object.)
Public methodGetHashCode (Overrides Object.GetHashCode().)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodToString (Inherited from Object.)
Public operatorStatic memberEqualityCompare two objects to see if they are identical.
Public operatorStatic memberInequalityCompare two objects to see if they are identical.

The FromEventPattern operator works with events that take an object sender and some EventArgs, and uses reflection to find add/remove methods. It then converts the given event into an observable sequence with an EventPattern type that captures both the sender and the event arguments.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
© 2014 Microsoft. All rights reserved.