Xamarin in short

6
Juha Ristolainen (@Riussi) / Futurice Ltd (@futurice) Xamarin in short 8/7/2014

description

Brief description of Xamarin cross-platform framework

Transcript of Xamarin in short

Page 1: Xamarin in short

Juha Ristolainen (@Riussi) / Futurice Ltd (@futurice)

Xamarin in short8/7/2014

Page 2: Xamarin in short

Mobile app development

*Image borrowed from Miguel de Icaza’s BUILD 2014 presentation

Traditional approach• Native apps developed in silos• No code re-use

8/7/2014

Page 3: Xamarin in short

Mobile app development

*Image borrowed from Miguel de Icaza’s BUILD 2014 presentation

Xamarin approach• Share common code between

apps• Write native apps with C#

• Amount of platform specific code from a few case studies from Xamarin:

• iOS: 20-30%• Android: 15-20%• Windows Phone: 10-15%

8/7/2014

Page 4: Xamarin in short

What Xamarin offers

» C# + Full .NET Runtime (also F# compiler)

» Native UI (iOS + Android)

› Same native UI components

» Native performance

› Compiles from MSIL/CIL into native ARM-code

*Image borrowed from Miguel de Icaza’s BUILD 2014 presentation

Page 5: Xamarin in short

Xamarin approach

• Write native apps with C#

• App per platform, use normal platform idioms

• Native APIs wrapped in strongly typed C#

• Share common code between them

• Models, ViewModels, etc.

• Anything you can do on iOS and Android with Obj-C and Java you can do with Xamarin C#

58/7/2014 Futurice

Page 6: Xamarin in short

Sharing code

» Shared project

» New Universal App shared

» PCL (Portable Class Library)

» PCL + nuget

› Stick to public API contract that a PCL profile can compile

› Reference assembly that projects use

› Actual implementations can be platform specific and use which ever packages they want