Beginning Android™ Application Development

Beginning Android™ Application Development

Read it now on the O’Reilly learning platform with a 10-day free trial.

O’Reilly members get unlimited access to books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.

Book description

Create must-have applications for the latest Android OS

The Android OS is a popular and flexible platform for many of today's most in-demand mobile devices. This full-color guide offers you a hands-on introduction to creating Android applications for the latest mobile devices. Veteran author Wei Meng Lee accompanies each lesson with real-world examples to drive home the content he covers. Beginning with an overview of core Android features and tools, he moves at a steady pace while teaching everything you need to know to successfully develop your own Android applications.

Beginning Android Application Development pares down the most essential steps you need to know so you can start creating Android applications today.

Show and hide more Table of contents Product information

Table of contents

  1. Copyright
  2. CREDITS
  3. ABOUT THE AUTHOR
  4. ABOUT THE TECHNICAL EDITOR
  5. ACKNOWLEDGMENTS
  6. INTRODUCTION
    1. WHO THIS BOOK IS FOR
    2. WHAT THIS BOOK COVERS
    3. HOW THIS BOOK IS STRUCTURED
    4. WHAT YOU NEED TO USE THIS BOOK
    5. CONVENTIONS
    6. SOURCE CODE
    7. ERRATA
    8. P2P.WROX.COM
    1. 1.1. WHAT IS ANDROID?
      1. 1.1.1. Android Versions
      2. 1.1.2. Features of Android
      3. 1.1.3. Architecture of Android
      4. 1.1.4. Android Devices in the Market
      5. 1.1.5. The Android Market
      1. 1.2.1. Eclipse
      2. 1.2.2. Android SDK
      3. 1.2.3. Android Development Tools (ADT)
      4. 1.2.4. Creating Android Virtual Devices (AVDs)
      5. 1.2.5. Creating Your First Android Application
      6. 1.2.6. Anatomy of an Android Application
      1. 2.1. UNDERSTANDING ACTIVITIES
        1. 2.1.1. Applying Styles and Themes to Activity
        2. 2.1.2. Hiding the Activity Title
        3. 2.1.3. Displaying a Dialog Window
        4. 2.1.4. Displaying a Progress Dialog
        1. 2.2.1. Resolving Intent Filter Collision
        2. 2.2.2. Returning Results from an Intent
        3. 2.2.3. Passing Data Using an Intent Object
        1. 2.3.1. Understanding the Intent Object
        2. 2.3.2. Using Intent Filters
        3. 2.3.3. Adding Categories
        1. 3.1. UNDERSTANDING THE COMPONENTS OF A SCREEN
          1. 3.1.1. Views and ViewGroups
          2. 3.1.2. LinearLayout
          3. 3.1.3. AbsoluteLayout
          4. 3.1.4. TableLayout
          5. 3.1.5. RelativeLayout
          6. 3.1.6. FrameLayout
          7. 3.1.7. ScrollView
          1. 3.2.1. Anchoring Views
          2. 3.2.2. Resizing and Repositioning
          1. 3.3.1. Persisting State Information during Changes in Configuration
          2. 3.3.2. Detecting Orientation Changes
          3. 3.3.3. Controlling the Orientation of the Activity
          1. 3.5.1. Overriding Methods Defined in an Activity
          2. 3.5.2. Registering Events for Views
          1. 4.1. BASIC VIEWS
            1. 4.1.1. TextView View
            2. 4.1.2. Button, ImageButton, EditText, CheckBox, ToggleButton, RadioButton, and RadioGroup Views
            3. 4.1.3. ProgressBar View
            4. 4.1.4. AutoCompleteTextView View
            1. 4.2.1. TimePicker View
              1. 4.2.1.1. Displaying the TimePicker in a Dialog Window
              1. 4.2.2.1. Displaying the DatePicker View in a Dialog Window
              1. 4.3.1. ListView View
                1. 4.3.1.1. Customizing the ListView
                1. 5.1. USING IMAGE VIEWS TO DISPLAY PICTURES
                  1. 5.1.1. Gallery and ImageView Views
                  2. 5.1.2. ImageSwitcher
                  3. 5.1.3. GridView
                  1. 5.2.1. Creating the Helper Methods
                  2. 5.2.2. Options Menu
                  3. 5.2.3. Context Menu
                  1. 5.3.1. AnalogClock and DigitalClock Views
                  2. 5.3.2. WebView
                  1. 6.1. SAVING AND LOADING USER PREFERENCES
                    1. 6.1.1. Using getSharedPreferences()
                    2. 6.1.2. Using getPreferences()
                    1. 6.2.1. Saving to Internal Storage
                    2. 6.2.2. Saving to External Storage (SD Card)
                    3. 6.2.3. Choosing the Best Storage Option
                    4. 6.2.4. Using Static Resources
                    1. 6.3.1. Creating the DBAdapter Helper Class
                    2. 6.3.2. Using the Database Programmatically
                      1. 6.3.2.1. Adding Contacts
                      2. 6.3.2.2. Retrieving All the Contacts
                      3. 6.3.2.3. Retrieving a Single Contact
                      4. 6.3.2.4. Updating a Contact
                      5. 6.3.2.5. Deleting a Contact
                      6. 6.3.2.6. Upgrading the Database
                      1. 6.3.3.1. Bundling the Database with an Application
                      1. 7.1. SHARING DATA IN ANDROID
                      2. 7.2. USING A CONTENT PROVIDER
                        1. 7.2.1. Predefined Query String Constants
                        2. 7.2.2. Projections
                        3. 7.2.3. Filtering
                        4. 7.2.4. Sorting
                        1. 7.3.1. Using the Content Provider
                        1. 8.1. SMS MESSAGING
                          1. 8.1.1. Sending SMS Messages Programmatically
                          2. 8.1.2. Getting Feedback after Sending the Message
                          3. 8.1.3. Sending SMS Messages Using Intent
                          4. 8.1.4. Receiving SMS Messages
                            1. 8.1.4.1. Updating an Activity from a BroadcastReceiver
                            2. 8.1.4.2. Invoking an Activity from a BroadcastReceiver
                            1. 8.3.1. Downloading Binary Data
                            2. 8.3.2. Downloading Text Files
                            3. 8.3.3. Accessing Web Services
                            4. 8.3.4. Performing Asynchronous Calls
                            1. 9.1. DISPLAYING MAPS
                              1. 9.1.1. Creating the Project
                              2. 9.1.2. Obtaining the Maps API Key
                              3. 9.1.3. Displaying the Map
                              4. 9.1.4. Displaying the Zoom Control
                              5. 9.1.5. Changing Views
                              6. 9.1.6. Navigating to a Specific Location
                              7. 9.1.7. Adding Markers
                              8. 9.1.8. Getting the Location That Was Touched
                              9. 9.1.9. Geocoding and Reverse Geocoding
                              1. 9.2.1. Monitoring a Location
                              1. 10.1. CREATING YOUR OWN SERVICES
                                1. 10.1.1. Performing Long-Running Tasks in a Service
                                2. 10.1.2. Performing Repeated Tasks in a Service
                                3. 10.1.3. Executing Asynchronous Tasks on Separate Threads Using IntentService
                                1. 11.1. PREPARING FOR PUBLISHING
                                  1. 11.1.1. Versioning
                                  2. 11.1.2. Digitally Signing Your Android Applications
                                  1. 11.2.1. Using the adb.exe Tool
                                  2. 11.2.2. Using a Web Server
                                  3. 11.2.3. Publishing on the Android Market
                                    1. 11.2.3.1. Creating a Developer Profile
                                    2. 11.2.3.2. Submitting Your Apps
                                    1. A.1. GETTING AROUND IN ECLIPSE
                                      1. A.1.1. Workspaces
                                      2. A.1.2. Package Explorer
                                      3. A.1.3. Using Projects from Other Workspaces
                                      4. A.1.4. Editors
                                      5. A.1.5. Perspectives
                                      6. A.1.6. Auto Import of Namespaces
                                      7. A.1.7. Code Completion
                                      8. A.1.8. Refactoring
                                      1. A.2.1. Setting Breakpoints
                                      2. A.2.2. Exceptions
                                      1. B.1. USES OF THE ANDROID EMULATOR
                                      2. B.2. INSTALLING CUSTOM AVDS
                                      3. B.3. EMULATING REAL DEVICES
                                      4. B.4. SD CARD EMULATION
                                      5. B.5. EMULATING DEVICES WITH DIFFERENT SCREEN SIZES
                                      6. B.6. EMULATING PHYSICAL CAPABILITIES
                                      7. B.7. SENDING SMS MESSAGES TO THE EMULATOR
                                      8. B.8. MAKING PHONE CALLS
                                      9. B.9. TRANSFERRING FILES INTO AND OUT OF THE EMULATOR
                                      10. B.10. RESETTING THE EMULATOR
                                      1. C.1. CHAPTER 1 ANSWERS
                                      2. C.2. CHAPTER 2 ANSWERS
                                      3. C.3. CHAPTER 3 ANSWERS
                                      4. C.4. CHAPTER 4 ANSWERS
                                      5. C.5. CHAPTER 5 ANSWERS
                                      6. C.6. CHAPTER 6 ANSWERS
                                      7. C.7. CHAPTER 7 ANSWERS
                                      8. C.8. CHAPTER 8 ANSWERS
                                      9. C.9. CHAPTER 9 ANSWERS
                                      10. C.10. CHAPTER 10 ANSWERS
                                      11. C.11. CHAPTER 11 ANSWERS
                                      Show and hide more

                                      Product information

                                      • Title: Beginning Android™ Application Development
                                      • Author(s): Wei-Meng Lee
                                      • Release date: April 2011
                                      • Publisher(s): Wrox
                                      • ISBN: 9781118017111