c# - what is the difference between these two methods? -
system.net.mail.smtpclient has 2 methods confused.
1 . sendasync(mailmessage, object)
sends specified e-mail message smtp server delivery. method not block calling thread , allows caller pass object method invoked when operation completes. -msdn
2 . sendmailasync(mailmessage)
sends specified message smtp server delivery asynchronous operation. -msdn
notice names of 2 methods different not overload. difference here?
i looking clear answer description given msdn both methods ambiguous (at least me is.)
the difference 1 sendmailasync uses new async/await technology , other uses old callback technology. , more importantly, object that's passed passed event handler userstate when method completes.
Comments
Post a Comment