Events
An event is a C# language element that indicates a certain, user-defined, occurrence. It is a mechanism that initiates a dynamic form of communication between program elements. Rather than a procedural flow of control from one part of a program to another, events are the way to establish connection between program occurrences and resulting actions during runtime processing.
Events are used to notify interested listeners of various occurrences during a program's lifetime. They're used in C# components to provide a callback functionality in programs. This produces a level of efficiency not available in many languages where switch statements and object-hierarchy searching are the norm for invoking dynamic functionality.
Events derive their ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access