Android Tutorial: Services

Android Tutorial: Services

So far in this book, everything you have learned is related to activities. It is now time to present another Android component, the service. A service has no user interface and runs in the background. It is suitable for long-running operations. This article explains how to create a service and provides an example. Overview As…

Android Tutorial: Asynchronous Tasks

Android Tutorial: Asynchronous Tasks

This article talks about asynchronous tasks and explains how to handle them using the AsyncTask class. It also presents a photo editor application that illustrates how this class should be used. Overview The android.os.AsyncTask class is a utility class that makes it easy to handle background processes and publish progress updates on the UI thread….

Android Tutorial: Learning how to handling the Handler

Android Tutorial: Learning how to handling the Handler

One of the most interesting and useful types in the Android SDK is the Handler class. Most of the time, it is used to process messages and schedule a task to run at a future time. This article, explains what the class is good for and offers examples. Previous article: Android Tutorial: Camera API Overview The…

Android Tutorial: Sound Recorder

Android Tutorial: Sound Recorder

Android Sound Recorder The Android platform ships with a multitude of APIs, including one for recording audio and video. In this article, you learn how to use the MediaRecorder class to sample sound levels. This is the same class you used for making videos in Android Tutorial: Video Recording API The MediaRecorder Class Support for multimedia…

Android Tutorial: Video Recording API

Android Tutorial: Video Recording API

The easiest way to provide video-making capability in your application is to use a built-in intent to activate an existing activity. However, if you need more than what the default application can provide, you need to get your hands dirty and work with the API directly. This chapter shows how to use both methods for…

Android Tutorial: Camera API

Android Tutorial: Camera API

Almost all Android handsets and tablets come with one or two cameras. You can use a camera to take still pictures by starting an activity in the built-in Camera application or using the Camera API. This chapter shows how to use both approaches. Overview An Android application can call another application to use one or…

Android Tutorial: Database System

Android Tutorial: Database System

Android has its own technology for working with databases and it has nothing to do with Java Database Connectivity (JDBC), the technology Java developers use for accessing data in a relational database. In addition, Android ships with SQLite, an open-source database. This chapter shows how to work with the Android Database API and the SQLite…

Android Tutorial: Storage System

Android Tutorial: Storage System

Reading from and writing to a file are some of the most common operations in any type of application, including Android. In this article, you will learn how Android structures its storage areas and how to use the Android File API. Overview Android devices offer two storage areas, internal and external. The internal storage is…

Android Tutorial: Preferences

Android Tutorial: Preferences

Android comes with a SharedPreferences interface that can be used to manage application settings as key/value pairs. SharedPreferences also takes care of the writing of data to a file. In addition, Android provides the Preference API with user interface (UI) classes that are linked to the default SharedPreferences instance so that you can easily create…

Android Tutorial: Animation with example

Android Tutorial: Animation with example

Animation is an interesting feature in Android that has been available since the very beginning (API Level 1). In this article, you will learn to use an Animation API called property animation, which was added to Honeycomb (API Level 11). The new API is more powerful than the previous animation technology called view animation. You…