1) What is the real definition for an Action delegate? some definitions describe it as a polymorphic conditional map , some say that it * is an applied decision table *.
(You may ask what you will achieve if you know the definition, if I know that I can understand its real purpose).
2) Thanks to Binary Worrier, Andrew Hare from stackoverflow for creating good examples. When i announce
string[] words = "This is as easy as it looks".Split(' '); `Array.ForEach(words, p => Console.WriteLine(p));`
I can understand what he is actually doing. But when I declare how C # interprets, when i declare
Dictionary<SomeEnum, Action<User>> methodList = new Dictionary<SomeEnum, Action<User>>() methodList.Add(SomeEnum.One, DoSomething); methodList.Add(SomeEnum.Two, DoSomethingElse);
Does it save the Actions collection in the dictionary ?. Unfortunately, since the example was incomplete, I did not get it.
3) What is the functional difference between Action , Function ,Predicate delagets?
c # delegates
user193276
source share