Working with Delegates in C# - ' Summary ' (
Page 6 of 6 )
Summary
This article focused on delegates and explained why they are valuable to C# application development. Delegates allow you to refer to methods to dynamically invoke code and call multiple methods together. When executed, each member of a delegate's invocation list is executed synchronously, in the order they were added. A delegate's invocation list can be manipulated by adding and removing delegates.
One of the primary uses of delegates in .NET is to implement callback methods for events. Events are safer than delegates for callbacks because they protect against accidental assignment and provide protection against direct invocation from outside code. Delegates allow you to refer to methods, invoke multiple methods simultaneously, and are the underlying mechanism for implementing C# events.
Manipulating Society through Technology
Jeremy Bailenson, Director of the Virtual Human Interaction Lab at Stanford University, talks about virtual reality, avatars, Moore's law, how real world behaviors influence online reality, and societal manipulation through technology! >> Play video >> Read article >> See all videos