System.EventHandler Extension Methods

Raise(object sender)

Summary: Method for invoking/raising events.
Checks if the handler is null before attempting to call it.
C# Example:
EventHandler handler;
handler.Raise(object);

Raise(object sender, EventArgs e)

Summary: Method for invoking/raising events.
Checks if the handler is null before attempting to call it.
C# Example:
EventHandler handler;
handler.Raise(object, args);

Raise<TEventArgs>(object sender)

Summary: Method for invoking/raising events.
Checks if the handler is null before attempting to call it.
C# Example:
EventHandler<MyEventArgs> handler;
handler.Raise(object);

Raise<TEventArgs>(object sender, TEventArgs e)

Summary: Method for invoking/raising events.
Checks if the handler is null before attempting to call it.
C# Example:
EventHandler<MyEventArgs> handler;
MyEventArgs args;
handler.Raise(object, args);

Last edited May 4, 2012 at 2:07 PM by crpietschmann, version 3

Comments

No comments yet.