The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
Introducing Windows Runtime in Windows 8
1.
2.
3.
4.
5. User Interface
HTML5/CSS XAML DirectX Controls Data Binding
SVG Tiles Input Accessibility Printing
Devices Communications & Data
Geolocation Portable Sensors NFC Contracts Local & Cloud Storage Web
Notifications Streams
Media
Visual Background
Playback Capture PlayTo XML Networking SMS
Effects Transfer
Fundamentals
Application Services Threading/Timers Memory Management Authentication Cryptography Globalization
6. Metro style Apps Desktop Apps
View
XAML HTML / CSS
Controller
JavaScript
Model
C/C++ C#, VB HTML C C#
(Chakra) JavaScrip C++ VB
t
Windows Runtime APIs
System Services
Communication Graphics & Devices &
& Data Media Printing
Application Model Internet .NET
Explorer
Win32 SL
Kern
Windows Kernel Services
el
7.
8. Metro style app
Language Support
(CLR, WinJS, CRT)
Language Projection
UI Pickers Controls Media
Web Host (HTML,
CSS, JavaScript))
Windows XAML Storage Network …
Metadata &
Namespace
Windows Runtime Core Runtime Broker
Windows Core
13. Metro style app
Language Support
(CLR, WinJS, CRT)
Language Projection
UI Pickers Controls Media
Web Host (HTML,
CSS, JavaScript))
Windows XAML Storage Network …
Metadata &
Namespace
Windows Runtime Core Runtime Broker
Windows Core
14.
15.
16. Strings HSTRING Avoids copying in multiple languages
Basic Types INT32, UINT64 * Pointers allowed in limited cases
Enumerations enum AsyncStatus Flag or non-flag styles
Structures struct Rect; Can contain strings, but not interfaces
Simple Arrays INT32 [] For very basic collections
Interfaces IInspectable Methods are defined in interfaces
Generic Interfaces IVector<T> Type-generic interface
Runtime Class Windows.Storage.StorageFile Binds interfaces to make a class
19. Metro style app
Language Support
(CLR, WinJS, CRT)
Language Projection
Language Projection
UI Pickers Controls Media Web Host
(HTML, CSS, JavaS
Windows XAML Storage Network … cript))
Metadata &
Namespace
Windows Runtime Core Runtime Broker
Windows Core
20. IInspectable Shell32.dll
IUnknown
IStorageItemInformation
IStorageItem FileInformation
Object IStorageFile
Interfaces Runtime Class
Activation Store (Registry) Windows Metadata (Disk)
21. IInspectable C++ App
Projectio
n
IUnknown
C#/VB App
Projectio
CLR
n
Object
HTML App
Projectio
Chakra
n
Windows
Metadata
22. Projection creates
IInspectable
Start wrapper (using
returned
metadata) App
Object created by Projection
App asks to create Object bound to
implementation
object wrapper
code
WinRT Object Manager
Pass Name to Call DllGet- Wrapper returned
RoActivateInstance ActivationFactory to App
Find DLL using WinRT Object
Load DLL End
Catalog
23. IInspectable IInspectable
IUnknown IUnknown
Object Object
Projectio
Projectio
Windows App Windows App
n
n
Metadata v8 Metadata v9
25. Collections IVector<T>, IVectorView<T>, Iterators, Collections and events
IMap<T> cross-language
Delegates delegate Encapsulate the context to call
AsyncActionCompletedHandler back to an object
Events IApplicationLayout::LayoutChanged Lists of callback recipients
PropertySet interface IPropertySet Collection of items with varying
types
Async Interface ReceivePropertiesOperation A way to get a delayed result
without blocking
Contracts Windows.ApplicationModel. Connect Apps to Windows
DataTransferManager Extension Points
26. C++ App
STL-style
Projection
Array IEnumerabl C#/VB App
CLR
e
(T) style
Projection
HTML App
Chakra
JavaScript
Projection
Associative
Collection
27.
28. var new CameraCaptureUI
new Size
var await CameraCaptureUIMode
if
var new BitmapImage
await FileAccessMode
29. DllImport "avicap32.dll" "capCreateCaptureWindow"
static extern int
string int
int int int int
int int
DllImport "avicap32.dll"
static extern bool
int
MarshalAs UnmanagedType ref string
int
MarshalAs UnmanagedType ref string
int
// more and more of the same
31. App
Main UI Thread Threadpool
Windows
Windows Windows
UI
Object Object
Object
App Code App Code App Code
32.
33. Projection
App
Proxy
RuntimeBroker.exe
IInspectable
IUnknown
Windows
Runtime Object
Hinweis der Redaktion
varfpd = new Windows.Storage.Pickers.FileOpenPicker();fpd.fileTypeFilter.push(“.jpg”);fpd.fileTypeFilter.push(“.png”);fpd.pickSingleFileAsync().then(function (f) {img.src = window.URL.createObjectURL(f, false);});
Rich metadata – compare to windows.h; no relation between APIs
Private catalog – sharing between apps only through OS contracts
Thin projection layer for performance HSTRING storyInterface-based system; also for versioning; don’t want to say it day-to-day, so we got runtime classes (may evolve) = collection of functionality (can grow) based on a set of interfacesAlso generic interfaces, e.g. for vectors (type-safety for collections)
Don’t have to see the interfaces for regular purposes
C++ @ compile time, native code talks directly to the OS, no metadata read at runtimeC#/VB – mixture of metadata at runtime and compile time; RCWs generated by CLRJS – using metadata at runtime (dynamic language)
App doesn’t have to know much – everything happens behind the scenes (projection, WinRT)
Interface tied back to version of WindowsNew version of a class may have more interfacesTools can surface only the interfaces that are available in targeted OS versions for the app
Responsive, fluid platform
Not straightforward; P/Invoke, COM interop; rocket science
Compare to JS (apart from web workers), single-threaded environmentWork is done in background thread and in async operations
E.g. webcam promptSame for pickersConfidence for the user
API set, but also coreInterface-basedProjectionsUnderpins whole Windows platformThis level of detail is not needed to use it (debugging, etc.)One Windows API for each thingNatural and familiar in your language