SlideShare ist ein Scribd-Unternehmen logo
1 von 30
Kevin Stumpf
      Sr Software Engineer
kstumpf@interknowlogy.com
1.   Short introduction to Windows 8
2.   Windows Runtime (WinRT)
3.   Ways to develop Metro style apps for Windows 8
4.   Language Projection
5.   .NET’s role in the WinRT world
6.   XAML Differences to WPF
7.   Limitations
Important facts about Windows 8
1.   Hybrid OS
2.   Contracts
3.   Security System
App




                                   exposes
                publishes     Capabilities         restricts
Marketplace
                                                                        Broker




  Network (Client/Server)   Shared Directories                 Hardware
                            • Documents                        • Webcam
                            • Videos                           • Microphone
                            • Pictures                         • Proximity
                            • Music                            • GPS
1.    Knowledge applies to Desktop, Tablet & WP8
2.    The future is handheld
     1. Consumer Market
     2. Corporate Market (Hotel Check-Ins, Nurses, etc.)
3.    Develop commercial Apps for the Marketplace
4.    Strong Marketing from Microsoft as their Metro
      Ecosystem is vital
What the WinRT is about and
how it is integrated in the Win32
world
1.   Windows 8 Architecture
2.   WinRT vs. Win32
3.   WinRT API
Diagram from
http://bit.ly/GWmiLO
Diagram from
http://bit.ly/GWmiLO
asynchronous                              object oriented




   private
                  based on
               extended COM            Hierarchical
                              self-explanatory namespaces
Ways to develop Metro style apps
for Windows 8
1.    Dependency Diagram
2.    Metro style GUI development
     1. XAML
     2. “HTML5”/CSS
3.    Business Logic development
     1. JavaScript
     2. C# / VB
     3. C++
CX   WRL
How C#, JavaScript and C++ can
access the very same WinRT API
1.   WinRT API Metadata
2.   Projection explanation
3.   Projection areas
   WinRT API is described by .winmd Files
   Only Metadata, no implementation
   Foundation for the Language Projection
   Format follows ECMA-335 standard (Common Language Infrastructure)
   Independent from .NET, although it shares the same file format
   Files can be disassembled using IL
   Location: C:WindowsSystem32WinMetadata
WinRT API
(Metadata)




        Type
     Projections     Naming
                   Projections     Pattern
                                 Projections
.NET’s role in the WinRT world
1.   Integration in WinRT
2.   Metro style subset
3.   Visual Studio Project types
   C#/VB is NOT compiled against WinRT, it is still compiled to the same MSIL and then JIT-
    compiled at runtime by the CLR
   Executing CLR is the same for Desktop and Metro style based apps
   Desktop and Metro style both use .NET 4.5
   Metro style uses a constrained .NET subset which is just another .NET Profile (similar to
    Silverlight, WP7)
   Metro style apps in addition reference the WinRT by referencing Windows.winmd
   CLR communicates with WinRT




                                               A .NET developer's view of Windows 8 app
                                                                            development
   Subset restricts functionality at development time that would be forbidden by the application
    container at runtime
   Certain functionality was moved to the WinRT API (File access, network) to avoid redundancy
   Certain functionality was completely removed
    ◦ Dangerous/ Obsolete / Legacy APIs
    ◦ Badly designed APIs
    ◦ Not applicable anymore (Console, ASP.NET)
   Refactorings
   No exceptions with a full stack trace anymore! Instead, HRESULTS and wild guessing
   Debugging is limited: No reflection of the framework’s implementation is possible anymore
Major changes between WPF
XAML and WinRT XAML
   No MultiBindings
   No RadialGradient Brushes
   No PixelShader effects for UIElements
   No RelativeSource->FindAncestor Bindings
   No Implicit DataTemplates
   No Triggers, just VSM
   No Markup Extensions
WinRT Limitations and how you
can overcome some of them
   WinRT API only addresses the most common use
    cases
   A subset of COM and Win32 functionality is
    available to address other scenarios such as
    ◦   Accessing raw data from the webcam
    ◦   DirectX
    ◦   Diagnostics
    ◦   …
   .NET World: Pinvoke
   C++: Import the Win32 library and invoke the
    imported method
   JavaScript: No winmd metadata available => Not
    callable from JavaScript.
    Workaround: Build a C++ or .NET WinRT
    component that wraps the C++/COM functionality
    of interest
Kevin Stumpf – kstumpf@interknowlogy.com

Weitere ähnliche Inhalte

Ähnlich wie Win rt fundamentals

Introdot Netc Sharp En
Introdot Netc Sharp EnIntrodot Netc Sharp En
Introdot Netc Sharp En
Gregory Renard
 
jhkghj
jhkghjjhkghj
jhkghj
Admin
 
test2PPT
test2PPTtest2PPT
test2PPT
Admin
 
Sharing code win8 wp8
Sharing code win8 wp8Sharing code win8 wp8
Sharing code win8 wp8
matthidinger
 

Ähnlich wie Win rt fundamentals (20)

Windows 8
Windows 8Windows 8
Windows 8
 
Windows Mobile
Windows MobileWindows Mobile
Windows Mobile
 
.Net + novas tecnologias + win8
.Net + novas tecnologias + win8.Net + novas tecnologias + win8
.Net + novas tecnologias + win8
 
Microsoft .Net Technology
Microsoft .Net TechnologyMicrosoft .Net Technology
Microsoft .Net Technology
 
Windows 8 & JavaScript
Windows 8 & JavaScriptWindows 8 & JavaScript
Windows 8 & JavaScript
 
Introdot Netc Sharp En
Introdot Netc Sharp EnIntrodot Netc Sharp En
Introdot Netc Sharp En
 
O futuro do .NET : O que eu preciso saber
O futuro do .NET : O que eu preciso saberO futuro do .NET : O que eu preciso saber
O futuro do .NET : O que eu preciso saber
 
Deep Dive into WinRT
Deep Dive into WinRTDeep Dive into WinRT
Deep Dive into WinRT
 
Radu vunvulea building and testing windows 8 metro style applications using ...
Radu vunvulea  building and testing windows 8 metro style applications using ...Radu vunvulea  building and testing windows 8 metro style applications using ...
Radu vunvulea building and testing windows 8 metro style applications using ...
 
jhkghj
jhkghjjhkghj
jhkghj
 
Asp net
Asp netAsp net
Asp net
 
test2PPT
test2PPTtest2PPT
test2PPT
 
As Pdotnet
As PdotnetAs Pdotnet
As Pdotnet
 
Asp dot net
Asp dot netAsp dot net
Asp dot net
 
Asp net
Asp netAsp net
Asp net
 
Building apps with common code for windows 8 and windows phone 8 (WP8)
Building apps with common code for windows 8 and windows phone 8 (WP8)Building apps with common code for windows 8 and windows phone 8 (WP8)
Building apps with common code for windows 8 and windows phone 8 (WP8)
 
Introduction of c# day1
Introduction of c# day1Introduction of c# day1
Introduction of c# day1
 
Sharing code win8 wp8
Sharing code win8 wp8Sharing code win8 wp8
Sharing code win8 wp8
 
ASP.Net Technologies Part-1
ASP.Net Technologies Part-1ASP.Net Technologies Part-1
ASP.Net Technologies Part-1
 
Synapse india reviews sharing asp.net
Synapse india reviews sharing  asp.netSynapse india reviews sharing  asp.net
Synapse india reviews sharing asp.net
 

Kürzlich hochgeladen

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 

Kürzlich hochgeladen (20)

The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 

Win rt fundamentals

  • 1. Kevin Stumpf Sr Software Engineer kstumpf@interknowlogy.com
  • 2. 1. Short introduction to Windows 8 2. Windows Runtime (WinRT) 3. Ways to develop Metro style apps for Windows 8 4. Language Projection 5. .NET’s role in the WinRT world 6. XAML Differences to WPF 7. Limitations
  • 4. 1. Hybrid OS 2. Contracts 3. Security System
  • 5. App exposes publishes Capabilities restricts Marketplace Broker Network (Client/Server) Shared Directories Hardware • Documents • Webcam • Videos • Microphone • Pictures • Proximity • Music • GPS
  • 6. 1. Knowledge applies to Desktop, Tablet & WP8 2. The future is handheld 1. Consumer Market 2. Corporate Market (Hotel Check-Ins, Nurses, etc.) 3. Develop commercial Apps for the Marketplace 4. Strong Marketing from Microsoft as their Metro Ecosystem is vital
  • 7. What the WinRT is about and how it is integrated in the Win32 world
  • 8. 1. Windows 8 Architecture 2. WinRT vs. Win32 3. WinRT API
  • 11. asynchronous object oriented private based on extended COM Hierarchical self-explanatory namespaces
  • 12. Ways to develop Metro style apps for Windows 8
  • 13. 1. Dependency Diagram 2. Metro style GUI development 1. XAML 2. “HTML5”/CSS 3. Business Logic development 1. JavaScript 2. C# / VB 3. C++
  • 14. CX WRL
  • 15. How C#, JavaScript and C++ can access the very same WinRT API
  • 16. 1. WinRT API Metadata 2. Projection explanation 3. Projection areas
  • 17. WinRT API is described by .winmd Files  Only Metadata, no implementation  Foundation for the Language Projection  Format follows ECMA-335 standard (Common Language Infrastructure)  Independent from .NET, although it shares the same file format  Files can be disassembled using IL  Location: C:WindowsSystem32WinMetadata
  • 18. WinRT API (Metadata) Type Projections Naming Projections Pattern Projections
  • 19. .NET’s role in the WinRT world
  • 20. 1. Integration in WinRT 2. Metro style subset 3. Visual Studio Project types
  • 21. C#/VB is NOT compiled against WinRT, it is still compiled to the same MSIL and then JIT- compiled at runtime by the CLR  Executing CLR is the same for Desktop and Metro style based apps  Desktop and Metro style both use .NET 4.5  Metro style uses a constrained .NET subset which is just another .NET Profile (similar to Silverlight, WP7)  Metro style apps in addition reference the WinRT by referencing Windows.winmd  CLR communicates with WinRT A .NET developer's view of Windows 8 app development
  • 22. Subset restricts functionality at development time that would be forbidden by the application container at runtime  Certain functionality was moved to the WinRT API (File access, network) to avoid redundancy  Certain functionality was completely removed ◦ Dangerous/ Obsolete / Legacy APIs ◦ Badly designed APIs ◦ Not applicable anymore (Console, ASP.NET)  Refactorings
  • 23. No exceptions with a full stack trace anymore! Instead, HRESULTS and wild guessing  Debugging is limited: No reflection of the framework’s implementation is possible anymore
  • 24. Major changes between WPF XAML and WinRT XAML
  • 25.
  • 26. No MultiBindings  No RadialGradient Brushes  No PixelShader effects for UIElements  No RelativeSource->FindAncestor Bindings  No Implicit DataTemplates  No Triggers, just VSM  No Markup Extensions
  • 27. WinRT Limitations and how you can overcome some of them
  • 28. WinRT API only addresses the most common use cases  A subset of COM and Win32 functionality is available to address other scenarios such as ◦ Accessing raw data from the webcam ◦ DirectX ◦ Diagnostics ◦ …
  • 29. .NET World: Pinvoke  C++: Import the Win32 library and invoke the imported method  JavaScript: No winmd metadata available => Not callable from JavaScript. Workaround: Build a C++ or .NET WinRT component that wraps the C++/COM functionality of interest
  • 30. Kevin Stumpf – kstumpf@interknowlogy.com