xamarin: building native mobile, mac and windows apps in c#
Embed Size (px)
TRANSCRIPT

XamarinBuilding Native Mobile, Mac and Windows Apps in C#
Anuradha Wickramarachchi
Mithila WickramarathneVijini MallawaarachchiDimuthu Kariyawasam
(Interns)

•Introduction to Xamarin•Unique approach of Xamarin in developing apps•Mobile Software Development Lifecycle•Introducing Xamarin Studio•Demonstration of a Xamarin sample app
Outline

Introduction to Xamarin

Introduction to Xamarin
What is Xamarin?•Cross-platform implementations of the Common Language Infrastructure (CLI) and Common Language Specifications (often called Microsoft .NET)
• https://www.xamarin.com

Introduction to Xamarin
Silo Approach in mobile development?

Introduction to Xamarin
Xamarin to the rescue

Introduction to Xamarin
Why C#?Anything you can do in Java or Objective-C, you can do it in C# also•More Types, Less Typing
var•Stronger Types, Smarter Tools (with Generics)
Dictionary<string, UIImage>•Language-level Asynchronous programming support
Async, await•First-class Functions
items.Where(item => item.Published.Date == date).ToList()

Introduction to Xamarin
How Does Xamarin Work?•Xamarin offers two commercial products
1.Xamarin.iOS2.Xamarin.Android
•On iOS, Xamarin’s Ahead-of-Time ( AOT) Compiler compiles Xamarin.iOS applications directly to native ARM assembly code.•On Android, Xamarin’s compiler compiles down to Intermediate Language ( IL), which is then Just-in-Time ( JIT) compiled to native assembly when the application launches.

Introduction to Xamarin
Xamarin.iOS•Access any iOS SDK API•Invoke Objective-C code using C#•Build apps for Apple watch platform•Same day support for latest OS builds by Apple

Introduction to Xamarin
Xamarin.Android•Access any Android SDK API•Invoke Java code using C#•Build apps for Android wear•Up-to-date with latest release of Android

Introduction to Xamarin
Xamarin.Forms•Native UI for iOS, Android and windows mobile from a single shared C# codebase.•Create the UI in C# or XAML.•At runtime, mapped into native UI elements.

Introduction to Xamarin
Xamarin.iOS or Xamarin.Android is ideal•For apps that require native behavior•For accessing many platform-specific APIs•Where custom UI is more important than code sharing across the platforms

Introduction to Xamarin
Xamarin.Forms is ideal•For apps that require little platform specific functions•Where code sharing is more important than custom UI’s

Mobile Software Development Lifecycle

Mobile Software Development Lifecycle
Mobile Development SDLC5 major portions of the process
1. Inception2.Design3.Development4.Stabilization5.Deployment

Mobile Software Development Lifecycle
InceptionMajor considerations
•Competitive Advantage•Infrastructure Integration•Value•Form/Mobility

Mobile Software Development Lifecycle
DesignUX & UI Design

Mobile Software Development Lifecycle
Development & StabilizationCoding of the app begins during development phase
An idea is developed to a working prototype
Significant stages in Stabilization are:•Prototype•Alpha•Beta•Release Candidate
Use Xamarin Profiler for profiling

Mobile Software Development Lifecycle

Mobile Software Development Lifecycle
DistributionXamarin.iOS and Objective-C apps are distributed in exactly the same way as•Apple App Store•In-House Deployment•Ad-Hoc Deployment
Android apps are distributed via Google Play, AppBrain, Amazon App Store for Android, Handango and GetJar.
Windows Phone applications are distributed to users via the Windows Store

Introducing Xamarin Studio

Introducing Xamarin Studio
Xamarin Powerful Features•Complete Binding for the underlying SDKs•Objective-C, Java, C, and C++ Interoperability•Modern Language Constructs•Amazing Base Class Library (BCL)•Modern Integrated Development Environment (IDE)•Mobile Cross Platform Support

Introducing Xamarin Studio
Development Environments

Introducing Xamarin Studio

Introducing Xamarin Studio

Introducing Xamarin Studio

Introducing Xamarin Studio
Directly edit Storyboards
Double-click a storyboard file to edit it in the IDE. Drag-and-drop controls to build screens, name
controls to create fields, and double-click to add handlers without switching to Xcode.
More accurate than Xcode
View controllers are controls are a pixel-perfect representation of
screens as they will appear when running on iOS devices which
makes it much more accurate than Xcode.
Live-rendered custom controls
Unlike Xcode's Interface Builder, the Xamarin iOS Designer renders your custom views just as easy as it renders UIKit controls-live, with custom properties editable in the
properties pad.
Never touch a line of XML
Easily create Android screens by dragging controls onto the app
builder. And configuring them using the properties pad, without XML.
Multiple resolutions at once
Preview layouts across multiple screen resolutions and device form
factors simultaneously with the Xamarin Android Designer.
Perfect property editing
Quickly configure the appearance, layout, field names, and event handlers for controls and views using a sleek properties pad.
iOS
Android
iOS iOS
Android AndroidiOS

Demonstration of a Xamarin sample app

Q&A

Thank You