Hi,
Why was it decided to implement subscribing an observer to an event with
+= and -= operators and not providing some kind of .Add and .Remove methods?
Wouldnt this be nicer?
having it as something.Event Here += new BlahHandler(cla ss.method):
instead of
something.Event Here.Add(class. method); for +=
and
something.Event Here.Remove(cla ss.Method)
what other way are we going to add a callback method?
= ? then why not use singlecast delegates. we could always provide a
..clear() method
Just a thought
Why was it decided to implement subscribing an observer to an event with
+= and -= operators and not providing some kind of .Add and .Remove methods?
Wouldnt this be nicer?
having it as something.Event Here += new BlahHandler(cla ss.method):
instead of
something.Event Here.Add(class. method); for +=
and
something.Event Here.Remove(cla ss.Method)
what other way are we going to add a callback method?
= ? then why not use singlecast delegates. we could always provide a
..clear() method
Just a thought
Comment