Xamarin Mobile Application Development for Android - Second Edition
eBook - ePub

Xamarin Mobile Application Development for Android - Second Edition

Nilanchala Panigrahy

Condividi libro
  1. 296 pagine
  2. English
  3. ePUB (disponibile sull'app)
  4. Disponibile su iOS e Android
eBook - ePub

Xamarin Mobile Application Development for Android - Second Edition

Nilanchala Panigrahy

Dettagli del libro
Anteprima del libro
Indice dei contenuti
Citazioni

Informazioni sul libro

Develop, test, and deliver fully-featured Android applications using XamarinAbout This Book• Build and test multi-view Android applications using Xamarin.Android• Work with device capabilities such as location sensors and the camera• A progressive, hands-on guide to develop stunning Android applications using XamarinWho This Book Is ForIf you are a C# developer who wants to develop Android apps and enhance your existing skill set, then this book is ideal for you. Good working knowledge of C#, .NET, and object-oriented software development is assumed.What You Will Learn• Build a multi-view, orientation-aware Android application with navigation• Lay out content using the LinearLayout, RelativeLayout, and TableLayout layout managers• Use a ListView (AdapterView) and Adapter to build a view that is populated from server data• Consume REST web service to perform GET, UPDATE, DELETE operation• Use Android SQLite for data persistence and caching• Capture the current location of a device, determine the street address, and integrate with the map app• Test, debug, and deploy an Android appIn DetailTechnology trends come and go, but few have generated the excitement, momentum, or long-term impact that mobile computing has. Mobile computing impacts people's lives at work and at home on a daily basis. Many companies and individual developers are looking to become a part of the movement but are unsure how to best utilize their existing skills and assets. The Xamarin suite of products provides new opportunities to those who already have a significant investment in C# development skills and.NET code bases, and would like to enter into this new, exciting world.This example-oriented guide provides a practical approach to quickly learn the fundamentals of Android app development using C# and Xamarin.Android. It will lead you through building an Android app step-by-step with steadily increasing complexity.Beginning with an overview of the Android and Xamarin platforms to provide you with a solid understanding of the underlying platform, we gradually walk through building and testing a Points of Interest Android app using C# and the Xamarin.Android product. You will learn to create ListView and add detail view to your Android application. You will handle application behaviors on orientation changes, before learning the different techniques to manage resources and layouts to support multiple screen sizes. You will then access a SQLite database in a cross-platform way and add location features to your application. Finally, you will add camera integration to your application and deploy your app to the various Android app stores.Style and approachAn example-oriented, comprehensive guide to gain an understanding of both the Android and Xamarin platforms.

Domande frequenti

Come faccio ad annullare l'abbonamento?
È semplicissimo: basta accedere alla sezione Account nelle Impostazioni e cliccare su "Annulla abbonamento". Dopo la cancellazione, l'abbonamento rimarrà attivo per il periodo rimanente già pagato. Per maggiori informazioni, clicca qui
È possibile scaricare libri? Se sì, come?
Al momento è possibile scaricare tramite l'app tutti i nostri libri ePub mobile-friendly. Anche la maggior parte dei nostri PDF è scaricabile e stiamo lavorando per rendere disponibile quanto prima il download di tutti gli altri file. Per maggiori informazioni, clicca qui
Che differenza c'è tra i piani?
Entrambi i piani ti danno accesso illimitato alla libreria e a tutte le funzionalità di Perlego. Le uniche differenze sono il prezzo e il periodo di abbonamento: con il piano annuale risparmierai circa il 30% rispetto a 12 rate con quello mensile.
Cos'è Perlego?
Perlego è un servizio di abbonamento a testi accademici, che ti permette di accedere a un'intera libreria online a un prezzo inferiore rispetto a quello che pagheresti per acquistare un singolo libro al mese. Con oltre 1 milione di testi suddivisi in più di 1.000 categorie, troverai sicuramente ciò che fa per te! Per maggiori informazioni, clicca qui.
Perlego supporta la sintesi vocale?
Cerca l'icona Sintesi vocale nel prossimo libro che leggerai per verificare se è possibile riprodurre l'audio. Questo strumento permette di leggere il testo a voce alta, evidenziandolo man mano che la lettura procede. Puoi aumentare o diminuire la velocità della sintesi vocale, oppure sospendere la riproduzione. Per maggiori informazioni, clicca qui.
Xamarin Mobile Application Development for Android - Second Edition è disponibile online in formato PDF/ePub?
Sì, puoi accedere a Xamarin Mobile Application Development for Android - Second Edition di Nilanchala Panigrahy in formato PDF e/o ePub, così come ad altri libri molto apprezzati nelle sezioni relative a Ciencia de la computación e Desarrollo de aplicaciones. Scopri oltre 1 milione di libri disponibili nel nostro catalogo.

Informazioni

Anno
2015
ISBN
9781785280634

Xamarin Mobile Application Development for Android Second Edition


Table of Contents

Xamarin Mobile Application Development for Android Second Edition
Credits
About the Author
About the Reviewers
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Downloading the color images of this book
Errata
Piracy
Questions
1. The Anatomy of an Android App
The Android platform
Versions of Android
The Linux kernel
Native libraries
The Android runtime
The application framework
The application layer
The building blocks of the Android application
The Android packages (.apk)
The application manifest
Activities
The life cycle of an activity
The events of an activity
Fragments
The fragment life cycle
Services
Content providers
Broadcast receivers
Views and ViewGroups
Declarative versus programmatic View creation
User interface widgets
Common layouts
Adapter layouts
XML layout files
Element and attribute names
The View and layout identifiers
Using XML layouts from activities
Intents
Resources
The R.java file
Summary
2. The Xamarin.Android Architecture
Getting started with Xamarin
Why Xamarin.Android?
The benefits of using Xamarin.Android
The drawbacks of using Xamarin.Android
What is Mono?
Mono and Dalvik side by side
The Java Native Interface
Peer objects
Xamarin.Android application packaging
The Android bindings design
Design principles
C# properties
Delegates
Constants to enumerations
Development environments
Xamarin Studio
Xamarin for Visual Studio
IDE comparison
Compatibility
Summary
3. Creating the Points Of Interest App
The sample POIApp
Installing Xamarin.Android
Installing platforms and tools
Tools
The Android platform APIs
The Android platform Extras
Creating Android Virtual Devices
Cloning a virtual device
Speeding up the Android emulator
Using the x86 emulator
Third-party emulator solutions
The Xamarin Android Player
Genymotion
Creating the POI app
The Xamarin Studio IDE
The Project Options view
Understanding the project structure
The Xamarin Studio layout designer
The designer content layout
The Document Outline and Properties pads
Toolbox
Setting the target framework
Setting the app icon and package name
The launcher activity
Running and debugging the app
Debugging with an Android device
Enabling USB debugging
Installing a USB driver
Running apps on a device
Behind the scenes
The peer object
The AndroidManifest.xml file
Summary
4. Adding a List View
Creating the POI ListView layout
Creating POIListActivity
Creating the POI list row layout
Adding a RelativeLayout view group
Adding an ImageView widget
Adding a LinearLayout widget
Adding the name and address TextView classes
Adding the distance TextView
Creating the PointOfInterest apps entity class
Populating the ListView item
Creating POIListViewAdapter
Implementing a constructor
Implementing Count { get }
Implementing GetItemId()
Implementing the index getter method
Implementing GetView()
Reusing row Views
Populating row Views
Populating the list thumbnail image
Using UrlImageViewHelper
Adding Internet permissions
Hooking up POIListViewAdapter
Consuming the web service
An introduction to web services
Deploying the POI web service
Consuming REST web services asynchronously
Creating the POIService class
Asynchronous programming with async and await
Serializing and deserializing using Json.NET
Updating POIListActivity
Adding actions to ActionBar
Defining the menu XML file
Setting menus in OnCreateOptionsMenu()
Handling selection in OnOptionsItemSelected()
Handling the ListView click event
Handling no network condition
Toast
Summary
5. Adding a Details View
Creating the POIDetail layout
Understanding ScrollView
Using the TableLayout manager
Working with EditText's InputType
Creating POIDetailActivity
Adding navigation to POIDetailActivity
Navigation on the POIList item click
Receiving the data in POIDetailActivity
Binding variables to controls
Populating user interface widgets
Adding the save and delete actions
Disabling the delete action
Adding the save and delete actions in POIService
Consuming the web service to create or update a POI
Adding the CreateOrUpdatePOIAsync method to POIService
Consuming the web service to delete the POI
Adding the DeletePOIAsync method to POIService
Creating SavePOI()
Creating DeletePOI()
Adding validation
Using the EditText.Error property
Adding a delete confirmation prompt
Refreshing POIListActivity
Summary
6. Making Your App Orientation-aware
The Android behavior on configuration changes
Locking the Android application orientation
Dynamically requesting the orientation
Saving the activity state for configuration changes
Manually saving the activity state
Retaining the POI list scroll position
Building the orientation-aware layout
Manually handling the orientation behavior
Summary
7. Designing for Multiple Screen Sizes
An introduction to Android tablets
Creating an Android tablet emulator
An introduction to fragments
Creating a new fragment
Making POIApp compatible with Android tablets
Using fragments for displaying POIDetails
Creating the POIDetailsFragment layout
Creating the POIDetailFragment
Working with the save and delete actions
Adding the POIDetailFragment to POIDetailActivity
Modifying the POI details activity layout
Refactorin...

Indice dei contenuti