SlideShare ist ein Scribd-Unternehmen logo
1 von 21
.NET Stammtisch
Konstanz-Kreuzlingen
C# 6.0 ?!
Giesswein-Apps
Consulting | Entwicklung | Training
Twitter: @giessweinweb
About Me
• Ing. Christian Giesswein, BSc.
christian@giesswein-apps.at
• Die bunte Welt von C#/.NET
• C#, ASP.NET MVC, WCF, WPF, ADO.NET,..
• Fachzeitschriften & Konferenzen
• DotNetPro
• Windows Developer
• Giesswein-Apps
• Consulting, Development & Schulungen
Die Vergangenheit
C# 6.0 ?!
C# Vergangenheit
Jahr .NET-Version C#-Version zusätzlich eingeführte Sprachelemente
2005 .NET 2.0 / 3.0 C# 2.0
Generics
Partielle Typen
Anonyme Methoden
Iteratoren
Nullable-Datentyp
Private setters
Delegates
Kovarianz und Kontravarianz
2007 .NET 3.5 C# 3.0
Implizit typisierte Variablen
Objekt- und Collection-Initialisierer
Automatisch implementierte Properties
Anonyme Datentypen
Erweiterungsmethoden
LINQ
Lambda-Expressions
Expression-Trees
Partielle Methoden
2010 .NET 4.0 C# 4.0
Dynamisches Binding
Benannte und optionale Argumente
Generische Co- und Kontravarianz
Embedded Interop-Datentypen („NoPIA“)
Die Gegenwart
C# 6.0 ?!
Die Gegenwart
• Die Gegenwart sieht für uns natürlich :-)
folgendermaßen aus:
• .NET 4.5.2 (Mai 2014)
• C# 5.0
• TPL und async/await
• Visual Studio 2013 Update 2
• „Native“-Entwicklung: Windows Store App
• Webentwicklung: ASP.NET MVC 6.1 in der Cloud
C# Gegenwart
• Wir befinden uns gegenwärtig in einer Zeit in
der immer wieder hinterfragt wird:
• Typisierte Sprachen wie C# / VB.NET / Typescript?
• Untypisierte, dynamische Sprachen wie Javascript?
• Daraus ergibt sich natürlich die Frage:
• Hat meine Lieblingssprache XYZ noch eine Zukunft?
Die Zukunft
C# 6.0 ?!
C# Gegenwart
C# 6.0 ?!
Ja! Mit „Roslyn“
.NET Compiler Platform: Roslyn
• Ist die neue .NET Compiler Plattform für
Microsoft und „uns“
• Roslyn ist ein Compiler für C# der in C#
geschrieben wird
• Seit Anfang April ist eine CTP verfügbar und es
wurde Roslyn auch „Open-Source“ (Apache
License 2.0)
• https://roslyn.codeplex.com
.NET Compiler Platform: Roslyn
• Was interessiert den „Otto-Normal-
Programierer“ Roslyn?
• Visual Studio wird in naher zukunfg Roslyn
verwenden für all die Funktionen die wir heute
kennen und lieben
• Roslyn kann verwendet werden für Refactoring und
Codeanalyse
• Mehr Funktionen werden im Visual Studio
ermöglicht und es wird schneller mehr Funktionen
geben
• .NET Community kann mit Roslyn selbst
Erweiterungen entwickeln
Hands-On
C# 6.0 ?!
Hands-On
• Wer mit Roslyn experimentieren will und ein
wenig in die Zukunft blicken will:
• Download
• Roslyn kann für Visual Studio 2013
heruntergeladen und dort integriert werden
• C# „6.0“ heute schon möglich
C# Features mit Roslyn
Was “heute” schon funktioniert:
1. Initializers for auto-properties
2. Primary constructors
3. Using static on types
4. Declaration expressions
5. Exception filters
6. Binary literals and digit separators (Try them out in VB)
7. Indexed members and element initializers
8. Await in catch and finally blocks
9. Extension Add methods in collection initializers
Ausblick
C# 6.0 ?!
Ausblick
• Anfang Juni wurde eine CTP von Visual Studio
„14“ veröffentlicht und dieses Studio wird Out-
Of-The-Box mit Roslyn als Compiler geliefert
• Kann in einer VM oder per Azure Image
„ausprobiert“ werden
• Wieder neue Features in der IDE durch Roslyn
• Roslyn Roadmap
Codeanalyse mit Roslyn
C# 6.0 ?!
Codeanalyse mit Roslyn
• Mit Roslyn ist es „sehr leicht“ eigene
Codeanalysen zu erstellen
• Per MEF werden in Visual Studio Erweiterungen
für Roslyn geladen
•  Per Attribute „Export“ieren
Codeanalyse mit Roslyn
• CodeFix (Refactor)
• ICodeFixProvider
• [ExportCodeFixProvider(.., LanguageNames.CSharp)]
• CodeAnalyze (Info, Warnung, Fehler)
• ISyntaxNodeAnalyzer<SyntaxKind>
• ISymbolAnalyzer
• ExportDiagnosticAnalyzer(…,
LanguageNames.CSharp)]
• Momentan noch notwendig
• [DiagnosticAnalyzer]
Fragen?!
C# 6.0 – Ja!
Danke
Danke fürs vorbeischauen, mitdiskutieren,
gähnen und Senf abgeben.
Christian Giesswein
christian@giesswein-apps.at
www.giesswein-apps.at
@giessweinweb

Weitere ähnliche Inhalte

Empfohlen

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by HubspotMarius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTExpeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 

Empfohlen (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

.NET Stammtisch Konstanz-Kreuzlingen C# 6.0

  • 1. .NET Stammtisch Konstanz-Kreuzlingen C# 6.0 ?! Giesswein-Apps Consulting | Entwicklung | Training Twitter: @giessweinweb
  • 2. About Me • Ing. Christian Giesswein, BSc. christian@giesswein-apps.at • Die bunte Welt von C#/.NET • C#, ASP.NET MVC, WCF, WPF, ADO.NET,.. • Fachzeitschriften & Konferenzen • DotNetPro • Windows Developer • Giesswein-Apps • Consulting, Development & Schulungen
  • 4. C# Vergangenheit Jahr .NET-Version C#-Version zusätzlich eingeführte Sprachelemente 2005 .NET 2.0 / 3.0 C# 2.0 Generics Partielle Typen Anonyme Methoden Iteratoren Nullable-Datentyp Private setters Delegates Kovarianz und Kontravarianz 2007 .NET 3.5 C# 3.0 Implizit typisierte Variablen Objekt- und Collection-Initialisierer Automatisch implementierte Properties Anonyme Datentypen Erweiterungsmethoden LINQ Lambda-Expressions Expression-Trees Partielle Methoden 2010 .NET 4.0 C# 4.0 Dynamisches Binding Benannte und optionale Argumente Generische Co- und Kontravarianz Embedded Interop-Datentypen („NoPIA“)
  • 6. Die Gegenwart • Die Gegenwart sieht für uns natürlich :-) folgendermaßen aus: • .NET 4.5.2 (Mai 2014) • C# 5.0 • TPL und async/await • Visual Studio 2013 Update 2 • „Native“-Entwicklung: Windows Store App • Webentwicklung: ASP.NET MVC 6.1 in der Cloud
  • 7. C# Gegenwart • Wir befinden uns gegenwärtig in einer Zeit in der immer wieder hinterfragt wird: • Typisierte Sprachen wie C# / VB.NET / Typescript? • Untypisierte, dynamische Sprachen wie Javascript? • Daraus ergibt sich natürlich die Frage: • Hat meine Lieblingssprache XYZ noch eine Zukunft?
  • 9. C# Gegenwart C# 6.0 ?! Ja! Mit „Roslyn“
  • 10. .NET Compiler Platform: Roslyn • Ist die neue .NET Compiler Plattform für Microsoft und „uns“ • Roslyn ist ein Compiler für C# der in C# geschrieben wird • Seit Anfang April ist eine CTP verfügbar und es wurde Roslyn auch „Open-Source“ (Apache License 2.0) • https://roslyn.codeplex.com
  • 11. .NET Compiler Platform: Roslyn • Was interessiert den „Otto-Normal- Programierer“ Roslyn? • Visual Studio wird in naher zukunfg Roslyn verwenden für all die Funktionen die wir heute kennen und lieben • Roslyn kann verwendet werden für Refactoring und Codeanalyse • Mehr Funktionen werden im Visual Studio ermöglicht und es wird schneller mehr Funktionen geben • .NET Community kann mit Roslyn selbst Erweiterungen entwickeln
  • 13. Hands-On • Wer mit Roslyn experimentieren will und ein wenig in die Zukunft blicken will: • Download • Roslyn kann für Visual Studio 2013 heruntergeladen und dort integriert werden • C# „6.0“ heute schon möglich
  • 14. C# Features mit Roslyn Was “heute” schon funktioniert: 1. Initializers for auto-properties 2. Primary constructors 3. Using static on types 4. Declaration expressions 5. Exception filters 6. Binary literals and digit separators (Try them out in VB) 7. Indexed members and element initializers 8. Await in catch and finally blocks 9. Extension Add methods in collection initializers
  • 16. Ausblick • Anfang Juni wurde eine CTP von Visual Studio „14“ veröffentlicht und dieses Studio wird Out- Of-The-Box mit Roslyn als Compiler geliefert • Kann in einer VM oder per Azure Image „ausprobiert“ werden • Wieder neue Features in der IDE durch Roslyn • Roslyn Roadmap
  • 18. Codeanalyse mit Roslyn • Mit Roslyn ist es „sehr leicht“ eigene Codeanalysen zu erstellen • Per MEF werden in Visual Studio Erweiterungen für Roslyn geladen •  Per Attribute „Export“ieren
  • 19. Codeanalyse mit Roslyn • CodeFix (Refactor) • ICodeFixProvider • [ExportCodeFixProvider(.., LanguageNames.CSharp)] • CodeAnalyze (Info, Warnung, Fehler) • ISyntaxNodeAnalyzer<SyntaxKind> • ISymbolAnalyzer • ExportDiagnosticAnalyzer(…, LanguageNames.CSharp)] • Momentan noch notwendig • [DiagnosticAnalyzer]
  • 21. Danke Danke fürs vorbeischauen, mitdiskutieren, gähnen und Senf abgeben. Christian Giesswein christian@giesswein-apps.at www.giesswein-apps.at @giessweinweb