Book Image

Learning Xamarin studio

By : William Smith
Book Image

Learning Xamarin studio

By: William Smith

Overview of this book

Table of Contents (16 chapters)
Learning Xamarin Studio
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Libraries


There are two project templates that need to be explored in more detail due to the power they provide to your applications. These are the Portable Class Library (PCL) and the Binding Library projects.

Portable Class Library

Developing true cross-platform applications would not be feasible without a significant amount of code sharing. Unfortunately, each platform is built to a different .NET Core Library Profile. This means you can't directly share code libraries between different platform solutions because each of these libraries is built to target unique profiles. There are three ways to work around this problem.

The first is to simply duplicate code across your projects. Maintaining multiple sets of duplicate code is tedious and prone to errors such as copy/paste fail. Duplicate code means you end up with multiple separate solutions instead of a cross-platform application. If code duplication was the only option it would be better to just write your applications in native than to...