Android for Programmers: An App-Driven Approach / Edition 2

Paperback (Print)
Buy New
Buy New from BN.com
$23.94
Used and New from Other Sellers
Used and New from Other Sellers
from $24.24
Usually ships in 1-2 business days
(Save 46%)
Other sellers (Paperback)
  • All (18) from $24.24   
  • New (14) from $24.75   
  • Used (4) from $24.24   

Overview

The professional programmer’s Deitel® guide to smartphone and tablet app development using Android 4.3 and 4.4, the Eclipse-based Android Development Tools and the new Android Studio

Billions of apps have been downloaded from Google Play™! This book gives you everything you’ll need to start developing great Android apps quickly and getting them published on Google Play™. The book uses an app-driven approach–each new technology is discussed in the context of seven fully tested Android apps, complete with syntax coloring, code highlighting, code walkthroughs and sample outputs. Apps you’ll develop include:

  • Welcome App
  • Cannon Game
  • Tip Calculator
  • Doodlz
  • Twitter® Searches
  • Address Book
  • Flag Quiz

The first-generation Android phones were released in October 2008. By October 2013, a Strategy Analytics report showed that Android had 81.3% of the global smartphone market share, compared to 13.4% for Apple, 4.1% for Microsoft and 1% for Blackberry (bit.ly/1aqIZXf). Billions of apps have been downloaded from Google Play. There are now more than one billion activated Android devices worldwide and more than 1.5 million Android devices are being activated daily (venturebeat.com/2013/09/03/android-hits-1bactivations-and-will-be-called-kitkat-in-nextversion). The opportunities for Android app developers are enormous.

This book presents leading-edge computing technologies for professional software developers. At the heart of the book is the Deitel “app-driven approach”–concepts are presented in the context of complete working Android apps, rather than using code snippets. The introduction and app test drives at the beginning of each chapter show one or more sample executions. The book’s source code is available at www.deitel.com/books/androidfp2.

The apps in this book were carefully designed to introduce you to key Android features and APIs. You’ll quickly learn everything you need to start building Android apps–beginning with a testdrive of the Doodlz app in Chapter 1, then building your first app in Chapter 2. By the time you reach Chapter 9, you’ll be ready to create your own apps for submission to Google Play and other app marketplaces. You’ll master the Google Play submission process, including uploading your apps, deciding whether to sell your apps or offer them for free, and marketing them using in-app advertising, social media, Internet public relations and more.

Practical, example-rich coverage of:

  • Android 4.3 and 4.4
  • Android Development Tools, Android Studio
  • Supporting Various Screen Sizes/Resolutions
  • Accessibility, Internationalization, Graphics
  • Activities, Fragments, Intents, Preferences
  • GUIs, Layouts, Menus, Resource Files, Lists, Adapters, Events, Touch/Gesture Processing
  • Immersive Mode, Printing Framework, PrintHelper
  • Assets (Images, Audio), View Animation
  • Threading, Collections, SQLite Database
  • Social sharing via implicit intents
  • Google Play™, App Publishing, Pricing, Monetization, Marketing, In-App Advertising, In-App Billing and more.

Visit www.deitel.com

  • Download code examples
  • For information on Deitel’s Dive Into® Series programming training courses delivered at organizations worldwide visit www.deitel.com/training or write to deitel@deitel.com
  • Join the Deitel social networking communities on Facebook® at deitel.com/DeitelFan, Twitter® @deitel, Google+ at google.com/+DeitelFan, LinkedIn® at bit.ly/DeitelLinkedIn, YouTube at youtube.com/user/DeitelTV and subscribe to the Deitel® Buzz Online e-mail newsletter at www.deitel.com/newsletter/ subscribe.html

The Deitel® Developer Series is designed for professional programmers. The series presents focused treatments on a growing list of emerging and mature technologies, including Android™ app development, iOS® app development, Java, C# and .NET, C++, C, JavaScript®, Internet and web development and more. Each book in the series contains the same live-code teaching methodology used in the Deitels’ How to Program Series college textbooks–most concepts are presented in the context of completely coded, working apps.

Deitel & Associates is an internationally recognized authoring and corporate training organization specializing in Android and iOS® app development, programming languages, object technology and Internet and web software technology. The company offers instructor-led courses delivered at client sites worldwide on programming languages and platforms, such as Android™ app development, iOS® app development, Java, Objective-C, C#, Visual Basic®, Visual C++®, C++, C, XML, Python, Perl®, object technology, Internet and web programming, and a growing list of additional programming and software-development courses. The founders of Deitel & Associates, Inc., are Paul Deitel and Dr. Harvey Deitel. The company’s training clients include many of the world’s largest corporations, government agencies, branches of the military and academic institutions. To learn more about Deitel & Associates, Inc., its professional books, college textbooks, e-books and LiveLessons video training, and its worldwide Dive-Into® Series instructor-led, on-site training curriculum, visit www.deitel.com/training or send an email to deitel@deitel.com. Join the Deitel social media communities on Facebook® (www.deitel.com/DeitelFan), Twitter® (@deitel), Google+ (google.com/+DeitelFan), LinkedIn® (bit.ly/DeitelLinkedIn) and YouTube (youtube.com/user/DeitelTV), and subscribe to the Deitel® Buzz Online newsletter (www.deitel.com/newsletter/subscribe.html).

Read More Show Less

Editorial Reviews

From the Publisher
“I really love what you’re doing with the book. It has the potential to become the best Android book on the market. It’s impressive to see so many well-explained useful examples of Android patterns.” –Dan Galpin, Android Advocate and author of Intro to Android Application Development

“I wish this book had been around when I started developing on Android. I haven’t seen any other books cover app publishing so well and the links provided throughout are an impressive collection. You get full applications that show multiple parts of the APIs working together.” –Douglas Jones, Senior Software Engineer, Fullpower Technologies

“By far, this is the quickest way to get comfortable writing applications for the #1 mobile operating system. I really enjoy the book. While the target of Android for Programmers is people with some development experience, even novices will find this book an interesting read and it will speed their immersion into Android development. The book starts by describing the Android development environment. Then each chapter introduces a core aspect of the Android platform by briefly explaining the topic, then illustrating the capability with working code. The sample apps demonstrate the topics of each chapter, which easily can be applied to your own projects.” –Eric J. Bowden, COO, Safe Driving Systems, LLC

“Teaches you the Android SDK through actual use. Shows you how to write an app in every chapter, explaining each aspect of the SDK as it’s encountered. Whether you’ve never touched Android or you have some apps under your belt already, this book is definitely worth picking up.” –Ian G. Clifton, Independent Contractor and Android App Developer

“The updates in the second edition truly add value. The authors captured the right mix of Android enhancements and masterfully wove them into solid, practical apps. Great job!” –Chuck Lasky, Northern Virginia Community College

“An excellent book for someone who has done Java development and wants to learn Android through examples–developers can quickly pick up Android development skills. The app-driven approach is unique–at the end of each chapter, you have a well-designed and functioning app! The technical depth is excellent.” –Arijit Sengupta, Wright State University

“The ‘Characteristics of Great Apps’ table is excellent. The authors present the goals of each app and provide an opportunity to test-drive it before describing its implementation.” –Jesus Ubaldo Quevedo-Torrero, University of Wisconsin–Parkside

“Addresses a compelling set of topics in a fun and instructive way. Creates UI/layouts with a depth I’ve not seen elsewhere. The Flag Quiz app is enjoyable–View animation adds a professional touch; clear description of key UI elements. The Address Book chapter is a good introduction to CRUD-type apps.” –Sebastian Nykopp, Chief Architect, Reaktor

“The Welcome app looks solid; great to see the integration of the layout editor. The Tip Calculator app is pretty cool; I love the deeper coverage of the lifecycle. The Favorite Twitter Searches app is a good way to demonstrate ScrollView. The Flag Quiz app is one of my favorites, covering delayed events, View animations and string arrays; I like the use of the AssetManager for the flags. The XML declaration and explanation of the tweened flag-shake animation are nicely done. Nice job of keeping the database queries out of the UI thread in the Address Book app.” –Dan Galpin, Android Advocate and author of Intro to Android Application Development

“Great job illustrating the Visual Layout Editor; I liked the approach of creating a project then building visual components without code; this makes it easy to experiment with other properties to customize the look of the app. The line-by-line explanations of the code are extremely valuable; this is a solid introduction to how Android works. Favorite Twitter Searches taught me things I didn’t know. The Flag Quiz app is a great chapter. The Cannon Game app is a nice introduction to animation. The Doodlz app chapter uses great examples to illustrate the different concepts. The Address Book app is a good introduction to database access on the Android platform that presents the structures required for SQLite databases.”–Eric J. Bowden, COO, Safe Driving Systems, LLC

“The Technologies Overviews are particularly nice. The Intro chapter gives a solid overview of Android. The Welcome app chapter is a nice intro to layouts, keeping it simple, while still using a common layout (RelativeLayout). Favorite Twitter Searches is a great chapter that introduces a lot of core concepts. App descriptions give a clear understanding of what’s being built; the code highlighting is helpful. Doodlz is a great app–anyone can identify with it. The Address Book app is a good intro to launching other Activities and utilizing a SQLite database.”–Ian G. Clifton, Independent Contractor and Android App Developer

“Chapter 1 is an easy introduction; thanks to the link to one of the blogs, I found an alternate emulator. Welcome App shows layouts and some controls and prepares the way for resource internationalization. The Tip Calculator app UI highlights all the tricky cases of TableLayout and TableRow, which makes it a valuable demonstration. The Favorite Twitter Searches app does a good job of introducing a number of important UI skills, especially using the LayoutInflater and the ScrollView to programmatically add UI elements. Flag Quiz uses a variety of tools, such as collections, AlertDialog.Builder and animations. I like the configuration check for screen size to set the orientation of the Doodlz app. I haven’t seen any other books cover app publishing so well.” –Douglas Jones, Senior Software Engineer, Fullpower Technologies

“Good Intro to overall Android, Java and OO concepts.”–Ronan ‘‘Zero’’ Schwarz, CIO, OpenIntents

“One of the best Android books. Does an excellent job explaining the Android platform; I love the car analogy to explain object-oriented terms. Tip Calculator does a good job showing how to create a GUI–I like using the Outline window. I’ve never published an app, but after seeing how easy it is, I have a couple that I’m considering publishing.” –Tony Cantrell, Georgia Northwestern Technical College

“The Flag Quiz is interesting, engaging and shows important concepts like fragments, animations and resource qualifiers. The Cannon Game is fun–a great way to demonstrate displaying moving objects on the screen.” –Arijit Sengupta, Wright State University

“By the end of each chapter the reader will have created a functional app while acquiring a working knowledge of the material. This is the most practical method to master app development. The Twitter Searches app is a great example to illustrate arrays, opening a website, creating key-value pairs, hiding the keyboard and interacting with the app.” –Dawn Wick, Southwestern Community College

“Apps use Android 4.4 KitKat features, like printing and immersive mode. Covers the details a developer needs to be successful. The Welcome App chapter is very good; creating the project with no code is nice. I like that Twitter Searches uses the web to connect the user to Twitter. The Cannon Game brings the basic elements together for a game–animation, sounds, etc.” –Jim Hathaway, Application Developer, Kellogg Company

“I really like how accessibility is covered; this is generally an afterthought for most developers. Chapter 9 contains useful information that’s hard to find, particularly in respect to marketing–this is something that developers struggle to discover.” –Michael Pardo, Mobiata

“Nice discussion of intents and how these are needed to start activities. Cannon Game is challenging, but well implemented and explained. Chapter 9, Google Play and App Business Issues, is perfect–the information about market shares and tools to convert Android apps into iOS apps is very motivating.” –Jesus Ubaldo Quevedo-Torrero, University of Wisconsin—Parkside

Read More Show Less

Product Details

  • ISBN-13: 9780133570922
  • Publisher: Prentice Hall
  • Publication date: 1/14/2014
  • Series: Deitel Developer Series
  • Edition number: 2
  • Pages: 368
  • Sales rank: 282,847
  • Product dimensions: 6.90 (w) x 9.00 (h) x 0.90 (d)

Meet the Author

Paul Deitel, Abbey Deitel and Harvey Deitel are from Deitel & Associates, Inc., the internationally recognized programming languages authoring and corporate training organization. Millions of people worldwide have used Deitel books, LiveLessons video training and online resource centers to master Android™ app development, iOS® app development, Java, C#, .NET, Visual Basic®, C++, Visual C++®, C, Internet and web programming, JavaScript®, XML, Perl®, Python, PHP and more.
Read More Show Less

Table of Contents

Preface xiv

Before You Begin xxiii

Chapter 1: Introduction to Android 1

1.1 Introduction 2

1.2 Android–The World’s Leading Mobile Operating System 3

1.3 Android Features 3

1.4 Android Operating System 7

1.5 Downloading Apps from Google Play 11

1.6 Packages 12

1.7 Android Software Development Kit (SDK) 13

1.8 Object-Oriented Programming: A Quick Refresher 16

1.9 Test-Driving the Doodlz App in an Android Virtual Device (AVD) 19

1.10 Building Great Android Apps 30

1.11 Android Development Resources 32

1.12 Wrap-Up 34

Chapter 2: Welcome App 35

2.1 Introduction 36

2.2 Technologies Overview 37

2.3 Creating an App 38

2.4 Android Developer Tools Window 44

2.5 Building the App’s GUI with the Graphical Layout Editor 48

2.6 Running the Welcome App 56

2.7 Making Your App Accessible 57

2.8 Internationalizing Your App 59

2.9 Wrap-Up 63

Chapter 3: Tip Calculator App 64

3.1 Introduction 65

3.2 Test-Driving the Tip Calculator App 66

3.3 Technologies Overview 67

3.4 Building the App’s GUI 70

3.5 Adding Functionality to the App 79

3.6 AndroidManifest.xml 87

3.7 Wrap-Up 88

Chapter 4: Twitter® Searches App 89

4.1 Introduction 90

4.2 Test-Driving the App 91

4.3 Technologies Overview 97

4.4 Building the App’s GUI 100

4.5 Building the MainActivity Class 109

4.6 AndroidManifest.xml 124

4.7 Wrap-Up 124

Chapter 5: Flag Quiz App 125

5.1 Introduction 126

5.2 Test-Driving the Flag Quiz App 128

5.3 Technologies Overview 132

5.4 Building the GUI and Resource Files 136

5.5 MainActivity Class 147

5.6 QuizFragment Class 153

5.7 SettingsFragment Class 165

5.8 SettingsActivity Class 166

5.9 AndroidManifest.xml 166

5.10 Wrap-Up 167

Chapter 6: Cannon Game App 168

6.1 Introduction 169

6.2 Test-Driving the Cannon Game App 171

6.3 Technologies Overview 171

6.4 Building the App’s GUI and Resource Files 173

6.5 Class Line Maintains a Line’s Endpoints 175

6.6 MainActivity Subclass of Activity 176

6.7 CannonGameFragment Subclass of Fragment 176

6.8 CannonView Subclass of View 178

6.9 Wrap-Up 196

Chapter 7: Doodlz App 198

7.1 Introduction 199

7.2 Technologies Overview 201

7.3 Building the App’s GUI and Resource Files 203

7.4 MainActivity Class 211

7.5 DoodleFragment Class 212

7.6 DoodleView Class 219

7.7 ColorDialogFragment Class 231

7.8 LineWidthDialogFragment Class 234

7.9 EraseImageDialogFragment Class 238

7.10 Wrap-Up 239

Chapter 8: Address Book App 241

8.1 Introduction 242

8.2 Test-Driving the Address Book App 245

8.3 Technologies Overview 245

8.4 Building the GUI and Resource Files 247

8.5 MainActivity Class 255

8.6 ContactListFragment Class 261

8.7 AddEditFragment Class 268

8.8 DetailsFragment Class 274

8.9 DatabaseConnector Utility Class 282

8.10 Wrap-Up 287

Chapter 9: Google Play and App Business Issues 289

9.1 Introduction 290

9.2 Preparing Your Apps for Publication 290

9.3 Pricing Your App: Free or Fee 295

9.4 Monetizing Apps with In-App Advertising 297

9.5 Monetizing Apps: Using In-App Billing to Sell Virtual Goods 298

9.6 Registering at Google Play 299

9.7 Setting Up a Google Wallet Merchant Account 300

9.8 Uploading Your Apps to Google Play 301

9.9 Launching the Play Store from Within Your App 302

9.10 Managing Your Apps in Google Play 303

9.11 Other Android App Marketplaces 303

9.12 Other Popular Mobile App Platforms 303

9.13 Marketing Your Apps 304

9.14 Wrap-Up 308

Index 310

Read More Show Less

Customer Reviews

Be the first to write a review
( 0 )
Rating Distribution

5 Star

(0)

4 Star

(0)

3 Star

(0)

2 Star

(0)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously

    If you find inappropriate content, please report it to Barnes & Noble
    Why is this product inappropriate?
    Comments (optional)