anug - intro to xamarin and xamarin.forms

62
Hi, I’m James. Xamarin, Developer Evangelist @JamesMontemagno Xamarin.com | @XamarinHQ

Upload: james-montemagno

Post on 22-Jun-2015

577 views

Category:

Engineering


2 download

DESCRIPTION

Introduction to Xamarin and the new Xamarin.Forms.

TRANSCRIPT

Page 1: ANUG - intro to Xamarin and Xamarin.Forms

Hi, I’m James.!Xamarin, Developer Evangelist!

@JamesMontemagno!!

Xamarin.com | @XamarinHQ!

Page 2: ANUG - intro to Xamarin and Xamarin.Forms

Windows Developer in Phoenix

Page 3: ANUG - intro to Xamarin and Xamarin.Forms

Mobile Developer in Seattle

Page 4: ANUG - intro to Xamarin and Xamarin.Forms

I had an opportunity.

Page 5: ANUG - intro to Xamarin and Xamarin.Forms

Productive environment

Shared code

High performance

Page 6: ANUG - intro to Xamarin and Xamarin.Forms
Page 7: ANUG - intro to Xamarin and Xamarin.Forms

The best language for Windows development. Modern Features • Advanced Tools • Proven Libraries • Large Community • Statically Typed

Page 8: ANUG - intro to Xamarin and Xamarin.Forms

Xamarin makes C# the best language for mobile development. Native Code Generation • Platform API Bindings • Code Sharing • Visual Studio

+

Page 9: ANUG - intro to Xamarin and Xamarin.Forms

Xamarin ‘embraced and extended’ .NET

Page 10: ANUG - intro to Xamarin and Xamarin.Forms

60 days to go

Page 11: ANUG - intro to Xamarin and Xamarin.Forms

35 days of C# Windows Store

35 days of Java

35 days of Objective-C

35 days of C# Windows Phone 140 DAYS!

Page 12: ANUG - intro to Xamarin and Xamarin.Forms

42 days of C# Windows Store/Phone

35 days of Java 35 days of Objective-C

112 DAYS!

Page 13: ANUG - intro to Xamarin and Xamarin.Forms

60 days of C#

70% code reuse

Development time cut in half

Page 14: ANUG - intro to Xamarin and Xamarin.Forms
Page 15: ANUG - intro to Xamarin and Xamarin.Forms

Success

Windows Store iOS Android Windows Phone

Page 16: ANUG - intro to Xamarin and Xamarin.Forms
Page 17: ANUG - intro to Xamarin and Xamarin.Forms

Architecting !Mobile Apps!

Page 18: ANUG - intro to Xamarin and Xamarin.Forms

Silo  Approach  

Build  Apps  Mul1ple  Times  

Page 19: ANUG - intro to Xamarin and Xamarin.Forms

Write  Once,  Run  Anywhere  Approach  

Lowest    Common  Denominator  

Page 20: ANUG - intro to Xamarin and Xamarin.Forms

Xamarin’s Unique Approach!

Native With !Code Sharing!

Page 21: ANUG - intro to Xamarin and Xamarin.Forms

Windows APIs!

Page 22: ANUG - intro to Xamarin and Xamarin.Forms

iOS APIs | 100% Coverage!

Page 23: ANUG - intro to Xamarin and Xamarin.Forms

Android APIs | 100% Coverage!

Page 24: ANUG - intro to Xamarin and Xamarin.Forms

Anything you can do in Objective-C, Swift, or Java !can be done in C# with Xamarin using Visual Studio!

Page 25: ANUG - intro to Xamarin and Xamarin.Forms

C# runs on 2.6 Billion Devices!

Page 26: ANUG - intro to Xamarin and Xamarin.Forms

How Xamarin Works

§  C# + .NET Runtime §  Native UI §  Native Performance

Page 27: ANUG - intro to Xamarin and Xamarin.Forms

Automatically test your app on!hundreds of mobile devices !

Create native iOS, Android, Mac and Windows apps in Visual Studio and C#

Page 28: ANUG - intro to Xamarin and Xamarin.Forms

Demo!

Page 29: ANUG - intro to Xamarin and Xamarin.Forms

20 Minute Break!!Get your free C# t-shirt:!xamarin.com/shirt!!Follow Me:!@JamesMontemagno!

@XamarinHQ!#Xamarin!

Page 30: ANUG - intro to Xamarin and Xamarin.Forms

Portable  Class  Libraries  

Page 31: ANUG - intro to Xamarin and Xamarin.Forms

Xamarin.Forms!

With Xamarin.Forms: !more code-sharing, native controls!

Traditional Xamarin approach!

Shared UI Code!

Page 32: ANUG - intro to Xamarin and Xamarin.Forms

Xamarin.Forms!

Quickly and easily build native user interfaces using shared code!!Xamarin.Forms elements map to native controls and behaviors!!Mix-and-match Xamarin.Forms with native APIs!!!!!!!!!!

Shared UI Code!

Page 33: ANUG - intro to Xamarin and Xamarin.Forms

What’s Included!§  40+ Pages, Layouts, and Controls!§  Build from code behind or XAML!

§  Two-way Data Binding!!§  Navigation!

§  Animation API!

§  Dependency Service!

§  Messaging Center!

Shared UI Code!

Page 34: ANUG - intro to Xamarin and Xamarin.Forms

Pages!

Content" MasterDetail" Navigation" Tabbed" Carousel"

Page 35: ANUG - intro to Xamarin and Xamarin.Forms

Layouts!

Stack" Absolute" Relative" Grid" ContentView" ScrollView" Frame"

Page 36: ANUG - intro to Xamarin and Xamarin.Forms

Controls!

ActivityIndicator! BoxView! Button! DatePicker! Editor!

Entry! Image! Label! ListView! Map!

OpenGLView! Picker! ProgressBar! SearchBar! Slider!

Stepper! TableView! TimePicker! WebView! EntryCell!

ImageCell! SwitchCell! TextCell! ViewCell!

Page 37: ANUG - intro to Xamarin and Xamarin.Forms

Page

StackLayout

Label Entry StackLayout

Content

Children

Button Button Image

Children

Page 38: ANUG - intro to Xamarin and Xamarin.Forms

DEMO 1!Xamarin.Forms Walkthrough!

Page 39: ANUG - intro to Xamarin and Xamarin.Forms

Data Binding!

Page 40: ANUG - intro to Xamarin and Xamarin.Forms

Model-View-ViewModel!

Model"View" ViewModel"

How to display information!

What to display!Flow of interaction!

Business Logic!Data objects!!

Events!

Data!Data!

Page 41: ANUG - intro to Xamarin and Xamarin.Forms

Model-View-ViewModel!

Model"View" ViewModel"

Xamarin.Forms Data Binding"

Events!

Data!

Page 42: ANUG - intro to Xamarin and Xamarin.Forms

Data Binding!

Page 43: ANUG - intro to Xamarin and Xamarin.Forms

Data Binding!

Page 44: ANUG - intro to Xamarin and Xamarin.Forms

Data Binding!

Page 45: ANUG - intro to Xamarin and Xamarin.Forms

Data Binding!

Page 46: ANUG - intro to Xamarin and Xamarin.Forms

Demo 2!Weather App!

Page 47: ANUG - intro to Xamarin and Xamarin.Forms

Extensibility!

§  Dependency Service!§  Lets shared code access platform-specific SDK features via an

Interface implementation!!!

Page 48: ANUG - intro to Xamarin and Xamarin.Forms

Extensibility!

§  Step 1: Interface!!!

Page 49: ANUG - intro to Xamarin and Xamarin.Forms

Extensibility!

§  Step 2: Implement on each Platform!

Page 50: ANUG - intro to Xamarin and Xamarin.Forms

Extensibility!

§  Step 3: Register with Dependency Service!

Page 51: ANUG - intro to Xamarin and Xamarin.Forms

Extensibility!

§  Step 4: Access from shared code!

Page 52: ANUG - intro to Xamarin and Xamarin.Forms

DEMO 3!Weather App +!Text to Speech!

Page 53: ANUG - intro to Xamarin and Xamarin.Forms

Animations API!

Page 54: ANUG - intro to Xamarin and Xamarin.Forms

www.github.com/JamesMontemagno/FormsAnimations

Page 55: ANUG - intro to Xamarin and Xamarin.Forms
Page 56: ANUG - intro to Xamarin and Xamarin.Forms
Page 57: ANUG - intro to Xamarin and Xamarin.Forms
Page 58: ANUG - intro to Xamarin and Xamarin.Forms

www.github.com/JamesMontemagno/FormsAnimations

Page 59: ANUG - intro to Xamarin and Xamarin.Forms

Resources!§  Documentation!§  http://developer.xamarin.com/guides/cross-platform/xamarin-forms/!

§  XAML Documentation!§  http://developer.xamarin.com/guides/cross-platform/xamarin-forms/

xaml-for-xamarin-forms/!!

§  Samples!§  https://github.com/xamarin/xamarin-forms-samples!

!!!

Page 60: ANUG - intro to Xamarin and Xamarin.Forms

Learn more!

Unrivaled Mobile Development Training!Live unlimited mobile development training from mobile experts, !in your time-zone, on your schedule and as often as you'd like!

xamarin.com/university

Page 61: ANUG - intro to Xamarin and Xamarin.Forms

Get Started Today: xamarin.com/download | Students: [email protected] "

Page 62: ANUG - intro to Xamarin and Xamarin.Forms

Q & A!!Get your free C# t-shirt:!xamarin.com/shirt!!Follow Me:!@JamesMontemagno!

@XamarinHQ!#Xamarin!