Posts

Showing posts from November, 2011

Android Adapters

Image
An Adapter object acts as a bridge between an AdapterView and the underlying data for that view. The Adapter provides access to the data items. The Adapter is also responsible for making a View for each item in the data set.
An AdapterView is a view whose children are determined by an Adapter.
Some examples of AdapterViews are ListView, GridView, Spinner and Gallery.
There are several types or sub-classes of Adapter:
ListAdapter: Extended Adapter that is the bridge between a ListView and the data that backs the list. Frequently that data comes from a Cursor, but that is not required. The ListView can display any data provided that it is wrapped in a ListAdapter.

ArrayAdapter: A ListAdapter that manages a ListView backed by an array of arbitrary objects. By default this class expects that the provided resource id references a single TextView.


Example:



package com.project.ListView;
import android.app.Activity; import android.os.Bundle; import android.view.View; import android.widget.AdapterView; im…

Itroduction To Android

Image
What is android ?                 Android is a software stack for mobile devices that includes an operating system, middleware and key applications.

        One of the most widely used mobile OS these days isANDROID.Androidis a software bunch comprising not only operating system but also middleware and key applications.Android Inc was founded in Palo Alto of California, U.S. by Andy Rubin, Rich miner, Nick sears and Chris White in 2003. which is later on purchased byGoogle in 2005. Presently,Google and Open handset allianceare owners of Android operating system. After original release there have been number of updates in the original version of Android.