Introduction

If you’ve got a burning idea for an application that you’re dying to share, or if you recognize the power and possibilities of the Android platform, you’ve come to the right place. This is a short book on an immense topic.

We don’t mean to alarm anyone right off the bat here, but let’s be honest: Android development is hard. Its architecture is dissimilar to that of many existing platforms (especially other mobile SDKs), there are many traps for beginners to fall into, and you might find yourself running to the Internet for answers. In exchange for its difficulty, however, Google’s Android offers unprecedented power, control, and—yes—responsibility to those who are brave enough to develop for it.

This is where our job comes in. We’re here to make the process of learning to write amazing Android software as simple as possible.

Who are we to ask such things of you? Chris Haseman has been writing mobile software in a professional capacity for ten years, and for five of those years, he’s been developing software for Android. He’s also written code that runs on millions of handsets throughout the world. Also, he has a beard. We all know that people with ample facial hair appear to be more authoritative on all subjects.

Kevin Grant has been developing for Android since its inception and has worked on a breadth of user-facing products, developing beautiful and intuitive interfaces for millions of users. While he doesn’t have a beard, we all know that people with a perpetual five o’clock shadow know how to get things done.

From here on out, we’re going to take this conversation into the first person. We banter enough amongst ourselves—it’s not necessary to confuse you in the process. So without further ado, in return for making this learning process as easy as possible, I ask for a few things:

Image You have a computer. My third-grade teacher taught me never to take anything for granted; maybe you don’t have a computer. If you don’t already have a computer, you’ll need one—preferably a fast one, because the Android emulator and Eclipse can use up a fair amount of resources quickly.


Image Note

Android is an equal-opportunity development platform. While I personally develop on a Mac, you can use any of the three major platforms (Mac, PC, or Linux).


Image You’re fluent in Java. Notice that I say fluent, not expert. Because you’ll be writing usable applications (rather than production libraries, at least to start), I expect you to know the differences between classes and interfaces. You should be able to handle threads and concurrency without batting an eyelash. Further, the more you know about what happens under the hood (in terms of object creation and garbage collection), the faster and better your mobile applications will be.

Yes, you can get through the book and even put together rudimentary applications without knowing much about the Java programming language. However, when you encounter problems—in both performance and possibilities—a weak foundation in the programming language may leave you without a solution.

Image You have boundless patience and endless curiosity. Your interest in and passion for Android will help you through the difficult subjects covered in this book and let you glide through the easy ones.

Throughout this book, I focus on how to write features, debug problems, and make interesting software. I hope that when you’ve finished the book, you’ll have a firm grasp of the fundamentals of Android software development.

All right, that’s quite enough idle talking. Let’s get started.


Image Note

If you’re more interested in the many “whys” behind Android, this book is a good one to start with, but it won’t answer every question you may have.


Who This Book Is For

This book is for people who have some programming experience and are curious about the wild world of Android development.

Who This Book Is Not For

This book is not for people who have never seen a line of Java before. It is also not for expert Android engineers with several applications under their belt.

How You Will Learn

In this book, you’ll learn by doing. Each chapter comes with companion sample code and clear, concise instructions for how to build that code for yourself. You’ll find the code samples on the book’s website (www.peachpit.com/androiddevelopanddesign).

What You Will Learn

You’ll learn the basics of Android development, from creating a project to building scalable UIs that move between tablets and phones.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset