Book Image

Mastering Cross-Platform Development with Xamarin

Book Image

Mastering Cross-Platform Development with Xamarin

Overview of this book

The main goal of this book is to equip you with the required know-how to successfully analyze, develop, and manage Xamarin cross-platform projects using the most efficient, robust, and scalable implementation patterns. This book starts with general topics such as memory management, asynchronous programming, local storage, and networking, and later moves onto platform-specific features. During this transition, you will learn about key tools to leverage the patterns described, as well as advanced implementation strategies and features. The book also presents User Interface design and implementation concepts on Android and iOS platforms from a Xamarin and cross-platform perspective, with the goal to create a consistent but native UI experience. Finally, we show you the toolset for application lifecycle management to help you prepare the development pipeline to manage and see cross-platform projects through to public or private release.
Table of Contents (19 chapters)
Mastering Cross-Platform Development with Xamarin
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

SQLite


SQLite database implementations provide a relational persisted data structure in mobile application projects. Unlike the general server/client model that is used by relational databases, SQLite is a local database implementation and the data is stored in application local storage. Both Xamarin.iOS and Xamarin.Android application projects can include a SQLite database and associated implementations.

In order to use SQLite, developers are to choose to between the cross-platform implementation of ADO.Net, where the SQL queries are supposed to be created and included as plain text, or use the linq-2-entities access model of the SQLite.Net portable class library. It is available as a NuGet package and a component.

SQLite.Net PCL

For the following demonstration, we will use the asynchronous version of the SQLite.Net library.

Implementation of the SQLite data access layer with SQLite.Net generally follows a code first database programming paradigm. In this pattern, developers first define their...