Your SlideShare is downloading. ×
C# 5.0 - Async/Await
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

C# 5.0 - Async/Await

1,730
views

Published on


0 Comments
3 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,730
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
50
Comments
0
Likes
3
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. C# 5.0 – Async/Await Elemar Jr.Twitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net]
  • 2. Apresentando Elemar JR 32 anos, pai, DEV e nerd Arquiteto, enxadrista, (ex) apaixonado por vinhos. Gosta de filosofia e teologia P&D na Promob onde trabalha há 14 anos Microsoft C# MVP janeiro 2012 Integrante do Void Podcast com Leandro Daniel [@leandronet] e Vinícius Quaiato [@vquaiato] Blogueiro e articulista elemarjr.net e www.infoq.com/br/author/Elemar-Jr. FOSS developer fluentil.org + github.com/elemarjr + elemarjr.github.comTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net]
  • 3. Evolução No que o C# melhorou Managed C# 1.0 VS 2002 Code Anonymous Nullable C# 2.0 VS 2005 Generics Methods Types Lambda Extension Expression Anonymous Implicit C# 3.0 VS 2008 LINQ Expressions Methods Tree Types Typing (var) Late Named Optional More COM C# 4.0 VS 2010 Binding Arguments Parameters support Async Caller C# 5.0 VS 2012 feature InformationTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net]
  • 4. Palavras “do cara” Por que Async?! Asynchronous programming is becoming the norm in modern, connected applications (Anders Hejlsberg)Twitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net]
  • 5. Síncrono Obtendo links no msdnTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226500
  • 6. Assíncrono Criando um “handler” (método) – há benefíciosTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226537
  • 7. Assíncrono Usando expressões LambdaTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226583
  • 8. Assíncrono Usando TPLTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226611
  • 9. Assíncrono Usando asyncTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226629
  • 10. Comparando Síncrono e AsyncTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net]
  • 11. Retornando Retornando AsyncTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226689
  • 12. Interface Considerando AsyncTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226728
  • 13. Interface Considerando AsyncTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226785
  • 14. (cont) Interface Considerando AsyncTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226785
  • 15. (cont) Interface Considerando AsyncTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226785
  • 16. Implementando Async Awaiter patternTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226785
  • 17. Implementando Async Awaiter pattern (exemplo 2)Twitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net] https://gist.github.com/3226841
  • 18. Finalizando Era isso! Parallel/Asyncronous Programming mais fácil com o Async CTP bit.ly/post-async-1 Async (advanced) – Returning Values, Cancellation, Awaiter pattern bit.ly/post-async-2 Visual Studio Async CTP – download bit.ly/download-async-ctpTwitter [@elemarjr] | Facebook [facebook.com/elemarjr] | Blog [elemarjr.net]