Apress Beginning Android Tablet Programming, Starting with Android Honeycomb for Tablets (2011).pdf
(
5148 KB
)
Pobierz
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
Beginning Android Tablet
Programming
Starting with Android Honeycomb for Tablets
Robbie Matthews
Beginning Android Tablet Programming: Starting with Android Honeycomb for Tablets
Copyright © 2011 by Robbie Matthews
All rights reserved. No part of this work may be reproduced or transmitted in any form or by any means,
electronic or mechanical, including photocopying, recording, or by any information storage or retrieval
system, without the prior written permission of the copyright owner and the publisher.
ISBN-13 (pbk): 978-1-4302-3783-9
ISBN-13 (electronic): 978-1-4302-3784-6
Trademarked names, logos, and images may appear in this book. Rather than use a trademark symbol
with every occurrence of a trademarked name, logo, or image we use the names, logos, and images only
in an editorial fashion and to the benefit of the trademark owner, with no intention of infringement of
the trademark.
The use in this publication of trade names, trademarks, service marks, and similar terms, even if they are
not identified as such, is not to be taken as an expression of opinion as to whether or not they are subject
to proprietary rights.
President and Publisher: Paul Manning
Lead Editor: Steve Anglin and Tom Welsh
Technical Reviewer: Stephen Bull and Peter Brownlow
Editorial Board: Steve Anglin, Mark Beckner, Ewan Buckingham, Gary Cornell, Morgan Engel,
Jonathan Gennick, Jonathan Hassell, Robert Hutchinson, Michelle Lowman, James Markham,
Matthew Moodie, Jeff Olson, Jeffrey Pepper, Douglas Pundick, Ben Renow-Clarke, Dominic
Shakeshaft, Gwenan Spearing, Matt Wade, Tom Welsh
Coordinating Editor: Anita Castro
Copy Editor: Mary Ann Fugate
Compositor: Bytheway Publishing Services
Indexer: SPI Global
Artist: SPI Global
Cover Designer: Anna Ishchenko
Distributed to the book trade worldwide by Springer Science+Business Media, LLC., 233 Spring Street,
6th Floor, New York, NY 10013. Phone 1-800-SPRINGER, fax (201) 348-4505, e-mail orders-ny@springer-
sbm.com, or visit www.springeronline.com.
For information on translations, please e-mail rights@apress.com, or visit www.apress.com.
Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use.
eBook versions and licenses are also available for most titles. For more information, reference our
Special Bulk Sales–eBook Licensing web page at www.apress.com/bulk-sales.
The information in this book is distributed on an “as is” basis, without warranty. Although every
precaution has been taken in the preparation of this work, neither the author(s) nor Apress shall have
any liability to any person or entity with respect to any loss or damage caused or alleged to be caused
directly or indirectly by the information contained in this work.
The source code for this book is available to readers at www.apress.com. You will need to answer
questions pertaining to this book in order to successfully download the code.
Contents at a Glance
About the Author.................................................................................................. xiv
About the Technical Reviewer .............................................................................. xv
Acknowledgments ............................................................................................... xvi
Some Notes on Using the Downloaded Code ...................................................... xvii
Chapter 1: Getting Started ......................................................................................1
Chapter 2: How Android Works.............................................................................27
Chapter 3: What Can You Do with an Android Tablet?.........................................53
Chapter 4: Beyond Java: Programming in Python and Friends ............................79
Chapter 5: Project 1: Media Player .....................................................................105
Chapter 6: Explorer .............................................................................................123
Chapter 7: Contact Manager ...............................................................................151
Chapter 8: Dude, Where’s My Car? .....................................................................175
Chapter 10: Remind Me ......................................................................................221
Chapter 11: Everything Else................................................................................243
Index ...................................................................................................................269
iv
Contents
About the Author.................................................................................................. xiv
About the Technical Reviewer .............................................................................. xv
Acknowledgments ............................................................................................... xvi
Some Notes on Using the Downloaded Code ...................................................... xvii
Chapter 1: Getting Started ......................................................................................1
A Short, Personal History of Portable Programming..........................................................1
The Advent of Android .......................................................................................................3
Preparing Your Computer ..................................................................................................4
Installing Your Development Environment................................................................................................ 4
Creating an Emulator Instance ................................................................................................................. 5
Setting Your Path...................................................................................................................................... 6
Your First Android Program ...............................................................................................6
Oh, No! Java! .....................................................................................................................9
A Quick Guide to Java......................................................................................................10
Structure................................................................................................................................................. 11
Primitives................................................................................................................................................ 12
Flow Control ........................................................................................................................................... 12
Objects.................................................................................................................................................... 13
Constructors, Initializers, and Overloading............................................................................................. 17
Where’s “Free”? ..................................................................................................................................... 19
String Handling....................................................................................................................................... 20
v
CONTENTS
Packages ................................................................................................................................................ 21
Lists and Maps ....................................................................................................................................... 22
Generics.................................................................................................................................................. 23
Inheritance and Interfaces...................................................................................................................... 24
Annotations............................................................................................................................................. 25
And Many More ...................................................................................................................................... 26
Summary ......................................................................................................................... 26
Chapter 2: How Android Works.............................................................................27
Basic Structure of Android Programs ..............................................................................27
Lifecycle ................................................................................................................................................. 38
Intents: What, Where, Why, and Are They Honorable? .................................................... 42
Intent Filters ........................................................................................................................................... 47
Common Intents ..................................................................................................................................... 48
Finally ..................................................................................................................................................... 48
Secretly Linux .................................................................................................................. 49
Summary ......................................................................................................................... 51
Chapter 3: What Can You Do with an Android Tablet?.........................................53
More Sensors Than the CIA .............................................................................................54
Lights, Camera, Action..................................................................................................... 63
Browsing for Fun and Profit.............................................................................................64
Managing Your Assets ............................................................................................................................ 66
Getting Fancy.......................................................................................................................................... 67
My Little Black Book—Managing Contacts .....................................................................69
Accessing Contacts ................................................................................................................................ 69
A Quick Side Trip into Lists..................................................................................................................... 72
Different Things to Access...................................................................................................................... 74
vi
Plik z chomika:
krupix.one
Inne pliki z tego folderu:
Wei-Meng Lee-Android application development cookbook_ 93 recipes for building winning apps-Wrox (2013).pdf
(32748 KB)
Apress Android Apps for Absolute Beginners (2011).pdf
(69762 KB)
Apress Android Tablets Made Simple, For Motorola XOOM Samsung Galaxy Tab Asus Toshiba and Other Tablets (2011).pdf
(75353 KB)
Addison-Wesley Introduction to Android App Development for the Kindle Fire (2012).pdf
(13997 KB)
Addison-Wesley Learning Android Application Programming for the Kindle Fire (2012).pdf
(17766 KB)
Inne foldery tego chomika:
Android Application Development Video Guide Poradnik
Apple iOS 5 and 6 Development eBooks Collection [PDF]
ASP.NET eBooks Collection [PDF]
books
Complete IT Books Pack
Zgłoś jeśli
naruszono regulamin