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

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

mysql - Pass value between different pages (form) with PHP -