PostSharp6.6//API Reference/Post­Sharp.​Aspects Namespace/IEvent­Binding Interface/IEvent­Binding Methods/IEvent­Binding.​Add­Handler Method

IEventBinding.AddHandler Method

Invoke the Add semantic on the next node in the chain of invocation.

Namespace:  PostSharp.Aspects
Assembly:  PostSharp (in PostSharp.dll) Version: 6.6.10.0 (6.6.10.0)
Syntax
C#
void AddHandler(
	ref Object instance,
	Delegate handler
)

Parameters

instance
Type: System.Object
Target instance on which the event is defined (null if the event is static).
handler
Type: System.Delegate
Handler to be added to the event.
Remarks

The instance parameter is passed by reference so that instance methods of value types ( struct in C#) are allowed to change the value of the instance.

See Also