Callback Function Usage
.NET Framework 1.1
Use an event if the following are true:
- A method signs up for the callback function up front, typically through separate Add and Remove methods.
- Typically, more than one object will want notification of the event.
- You want end users to be able to easily add a listener to the notification in the visual designer.
Use a delegate if the following are true:
- You want a C language style function pointer.
- You want a single callback function.
- You want registration to occur in the call or at construction time, not through a separate Add method.
Use an interface if the callback function requires complex behavior.