C# Delegates

Delegates provide a way of implementing callbacks much like function pointers in C/C++.
Simply create the delegate’s signature and (if you like) add it as a member to a class you wish to have a callback.

.

Create a static function in which to refer to and then assign the static function to the delegate like so:

.

Just make sure the signatures match (ie void, int , etc.)