Delegates Real Time Examples in C# | CSharp Delegates Real Time Examples

Описание к видео Delegates Real Time Examples in C# | CSharp Delegates Real Time Examples

Delegates Real Time Examples in C# | CSharp Delegates Real Time Examples
In this video, I am going to discuss Delegates in C# with Real-Time Examples. The delegates are one of the most important concepts that you need to understand as a C# developer. In many interviews, most of the interviewers ask you to explain the usage of delegates in the real-time project that you have worked on. Please watch the following two videos, where we discussed the basics of delegate and multicast delegates in C# with examples.
1. Single Cast Delegates in C# – (   • Delegates in C# with Examples | CShar...  ) Here we discussed the basics of Delegates in C# with examples.
2. Multicast Delegate in C# – (   • Multicast Delegates in C# with Exampl...  ) Here we discussed the Multicast Delegates in C# with examples.

The Delegates in C# are extensively used by framework developers. Let us understand delegates in C# with two real-time examples.

Delegate Real-Time Example1 in C#:
Let's say we have a class called Worker and this class has a method called DoWork. What our business requirement is when we invoke the DoWork method, we need to send a notification about the percentage of work done to the consumer as well as once the work is completed, we also need to send the notification. For example, how much work is done in 1 hour, how much work is done in 2 hours, how much work is done in 3 hours, and so on until the work is completed? And the DoWork method has no idea to whom to send the notifications. The caller of the DoWork method should decide to whom to send the notification. That means here we need to use call-back functions.

The text documents of this video: https://dotnettutorials.net/lesson/de...

#delegatesrealtimeexamples #delegatescsharpexamples #csharpdelegatesrealtimeexamples #csharp #dotnettutorials #csharptutorials

Delegates Real-Time Examples
Delegates Real-Time Examples in C#
Delegates Real-Time Examples in CSharp
C# Delegates Real-Time Examples
CSharp Delegates Real-Time Examples
Delegates Examples in C#
Delegates Examples in CSharp
C# Delegates Examples
CSharp Delegates Examples

Комментарии

Информация по комментариям в разработке