Book Image

Xamarin 4 By Example

By : Engin Polat, Mark Radacz
Book Image

Xamarin 4 By Example

By: Engin Polat, Mark Radacz

Overview of this book

The mobile app market is increasing exponentially every year. Xamarin Studio with its modern and powerful IDEs makes creating applications a lot easier by simplifying the development process. Xamarin will allow you and your team to create native applications by taking advantage of one of the most evolved programming language in the world: C#. This book will provide you with the basic skills you need to start developing mobile apps using C# and Xamarin. By working through the examples in each chapter, you will gain hands-on experience of creating a complete app that is fully functional by all means. Finally, you will learn to publish the app you created on the app market. Each project in this book will take you one step closer to becoming a professional app developer.
Table of Contents (16 chapters)
Xamarin 4 By Example
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
7
Monkey Puzzle Game – Processing Images

Example project - Xamarin Fast Food


First of all, we can create a new Xamarin.Forms PCL project and reuse the same base structure that we created in Chapter 4, Data – the Monkeys Catalog.

We can copy all the classes we've written inside the Base folder and we can prepare the empty subfolders of Core to define the business logic of our project.

To use the Base classes, we need to import into our projects the SQLite.Net PCL from the NuGet Package manager. It is a good practice to update all the packages before you start. As soon as a new package has been updated, we will be notified in the Packages folder. To update the package, right-click on the Packages folder and select Update from the contextual menu.

We can create, in the Business subfolder of the Core, the MenuItem class that contains the properties of the available items to order. A MenuItem will have the following:

  • Name

  • Price

  • RequiredSeconds

The class will be developed as follows:

public class MenuItem : BaseEntity<int> 
...