Android examples (example source code) Organized by topic






UI /

ActionBar 2Activity 45
ActivityInfo 1AdapterView 1
AdapterWrapper 1AlertDialog 5
AnalogClock 3AppWidgetManager 1
ArrayAdapter 1BackupHelper 1
BaseAdapter 1Button 29
CheckBox 6Chronometer 1
CursorAdapter 4DatePicker 3
Dialog 45Drag Drop 3
Drawer 2EditText 11
Focus 5Fragment 2
FrameLayout 1Gallery 6
GridView 6ImageSwitcher 3
ImageView 18Layout 53
LinearLayout 13ListActivity 26
ListAdapter 7ListPreference 1
ListView 16MapView 2
Menu 21PreferenceActivity 3
Progress 7RadioGroup 7
RatingBar 3RelativeLayout 4
RSSurfaceView 3ScrollView 5
SeekBar 3SlidingDrawer 2
Spinner 8SurfaceHolder 1
SurfaceView 3TabActivity 2
TabHost 7TableLayout 13
TableRow 2TextSwitcher 1
TextView 27TextWatcher 2
TimePicker 6Toast 13
VelocityTracker 1VideoView 1
View 14ViewFlipper 2
ViewGroup 4ViewWrapper 1
WebView 12Window 1

2D Graphics /

Arc 1Bitmap 69
Canvas 9Circle 1
Clipping 1Color 19
Drawable 13Font 7
Gif 1GLSurface 1
Icon 7Image 17
Jpeg 1Line 3
OpenGL 13Oval 1
Paint 4Path 6
Pattern 1Picture 1
Point 2Polygon 1
PorterDuffXfermode 2Rectangle 3
Region 1ShapeDrawable 1
Stroke 2Text 8
Thumbnail 1

Core Class /

Account 2Alarm 4
AndroidManifest 1Application 7
ApplicationInfo 1AssetManager 3
AsyncQueryHandler 1AsyncTask 1
BackupManager 1BroadcastReceiver 3
Browser 5Build 2
Clipboard 1Config 1
Configuration 1Contact 9
ContentProvider 1ContentResolver 3
Context 9Debug 1
DevicePolicyManager 1DisplayMetrics 1
DoBackgroundTask 1Environment 7
Fragment 8Geocoder 1
Handler 1IBinder 1
IME 2Intent 30
IntentService 1Location 4
Log 13Map 5
MapActivity 1NfcAdapter 3
Notification 7PackageInfo 5
PendingIntent 1Preference 2
PreferenceCategory 1Resources 10
SearchRecentSuggestionsProvider 1Settings 2
SharedPreferences 8SmsManager 1
Telephony 5Text To Speech 4
Timer 1TypedValue 1
Voice Recognition 1WallpaperService 1

Hardware /

Bluetooth 2Camera 10
CPU 7Display 1
External Storage 1Gps 2
Joystick 2Location 21
Memory 11PowerManager 1
Screen 15SDCard 7
Sensor 17SensorManager 2
System Information 9USB 2
Version 16Vibrator 2

Media /

Audio 13AudioRecord 1
MediaPlayer 12MediaRecorder 3
MediaScannerConnection 1MediaStore 3
Mp3 5Sound 3
SoundPool 1Video 15

User Event /

GestureStore 6Key 8
MotionEvent 1SimpleOnGestureListener 1
Touch 7

Network /

Connectivity 7ConnectivityManager 1
Cookie 1Download 10
Email 8Http Connection 40
IP 5NetworkInfo 2
Restful 3RSS 1
Service 20SMS 7
Socket 1SSL 2
Url 26WiFi 5

Animation /

AlphaAnimation 2Animation 16
AnimationSet 1AnimatorListener 1
LinearInterpolator 1RotateAnimation 1
ScaleAnimation 2TranslateAnimation 2

Game /

Game 3Math 5
Matrix 5Quaternion 2
Sprite 3Vector 10

Database /

SQLiteDatabase 11SQLiteOpenHelper 4

Security /

AES 3Authentication 3
DES 1MD5.xml 9
RSA 3SHA 17

File /

Buffer 24File Name 2
File 47Stream 18
Utilities 1

Development /

Exception 2I18N 2
JSON 13Random 6
Reflection 3Regular Expression 2
Resource 1System 6
Thread 7UncaughtExceptionHandler 3
Unicode 3UTF 6
Xml 17XmlPullParser 3
Zip 3

Date Type /

Array 27Base64 8
Byte 6Date 61
Float 12Hex 13
Integer 12List 4
String 67Time 31