This is a discussion on What's the difference between pointer and delegate? within the C# Programming forums, part of the Software Development category; What's the difference between pointer and delegate?...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
| |||
| A pointer is the address of the variable whereas Delegate is allows passing method of class to object of other class Rules in Delegation:- 1. In order to create a Delegate a Signature (parameter) must match Signature of object. 2. Define all the methods which has the same Signature as Delegate define. 3. Create the delegate object & pass the method as a parameter to Delegate. 4. Now call the encapsulated method using delegated object. The best example of Delegation model is ADO.NET Architecture & Event Handling in windows environment. |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| pointer concept in C | vigneshgets | C and C++ Programming | 1 | 08-14-2007 01:03 AM |
| What pointer type is used to implement the heterogeneous linked list in C? | sundarraja | C and C++ Programming | 1 | 08-02-2007 11:16 PM |
| Smart Pointer | sundarraja | C and C++ Programming | 1 | 07-25-2007 06:06 AM |
| What is the Object pointer in Java? | mobilegeek | Java Programming | 1 | 07-23-2007 06:08 AM |
| Why pointer can't use in Java | vadivelanvaidyanathan | Java Programming | 4 | 07-16-2007 11:23 PM |