What is a Delegate?

Author Topic: What is a Delegate?  (Read 140 times)

Offline beingchinmayTopic starter

  • Trade Count: (0)
  • Semi-Newbie
  • *
  • Thank You 0
  • Posts: 43
  • Karma: 0
  • Gender: Male
  • I am Chinmay
    • Fat Cutter
What is a Delegate?
« on: 11-22-2016, 04:13:12 »
•   Delegate in C# is similar to a function pointer in C or C++.

•   Delegate is type which holds the method(s) reference in an o ject. It is also referred as a type safe function pointers.

•   Delegate allows the programmer to encapsulate a reference to a method inside a delegate object.

•   The delegate object can then be pass d to code which can call the referenced method, without having to know at compile time which m thod will be invok d.

•   An interesting and useful property of a elegate is that it does not know or care about the class of the object that it references.


 

Related Topics

  Subject / Started by Replies Last post
0 Replies
101 Views
Last post 11-23-2016, 05:33:20
by beingchinmay
0 Replies
190 Views
Last post 11-29-2016, 03:37:47
by beingchinmay