Skip to main content

Android Architecture

See more basics on Android along with interview questions


Linux Kernal : This is the bottom most layer of architecture but it is the root of the whole system.It is important for the following features.
  • Hardware Abstraction
  • Memory Management Programs
  • Security Settings
  • Power Management Software
  • Other Hardware Drivers (Drivers are programs that control hardware devices.)
  • Support for Shared Libraries
  • Network Stack
Native Libraries and Android Runtime: Libraries guides the device in handling different types of data.For example Media Framework Library for handling audio video formats.Android Runtime includes a set of core Java libraries.It also include Dalvik Virtual MAchine for handling dex files. some of the open source Libraries are:
  • Surface Manager: composing windows on the screen
  • SGL: 2D Graphics
  • Open GL|ES: 3D Library
  • Media Framework: Supports playbacks and recording of various audio, video and picture formats.
  • Free Type: Font Rendering
  • WebKit: Browser Engine
  • libc (System C libraries)
  • SQLite
  • Open SSL
Application Framework Layer All application directly interact with this layer.They manages the basic functionalities of devices,such as voice control. Some of the important blocks of this layer are:
  • Activity Manager:
  • Manages the activity life cycle of applications. To understand the Activity component in Android in detail click here
  • Content Providers:
  • Manage the data sharing between applications. Our Post on Content Provider component describes this in greater detail
  • Telephony Manager:
  • Manages all voice calls. We use telephony manager if we want to access voice calls in our application.
  • Location Manager:
  • Location management, using GPS or cell tower
  • Resource Manager:
  • Manage the various types of resources we use in our Application
Application Layer This is the top most layer in the architecture.Users interact with this layer(for making calls,saving contacts,camera ..).

Comments

Popular posts from this blog

Spannable String in Android - URL Span ,Clickable Span, Rich-Style Formatting of Textview .....

See more Android Tutorials here....... Faster Loading images in GridViews or ListViews Spannable brings lots of possibility to TextView, includes displaying various appearance of a Text and onClick callbak. The SpannableString class allows you to easily format certain pieces which are called spans of a string, by applying CharacterStyle ie,color, font, ormake it a link . Here is an example where, explained how to use spannable string to give font size, color, linking a text via clickable span and through URL Span and to strike through the text. Lets go through the example : import android.os.Bundle; import android.text.SpannableString; import android.text.method.LinkMovementMethod; import android.text.style.ClickableSpan; import android.text.style.ForegroundColorSpan; import android.text.style.RelativeSizeSpan; import android.text.style.StrikethroughSpan; import android.text.style.URLSpan; import android.view.View; import android.widget.TextView; import android.widget.Toast;

Passing Images between Activities in Android

in First Activity: Intent intent=new Intent(FirstClass.this, SecondClass.class); Bundle bundle=new Bundle(); bundle.putInt("image",R.drawable.ic_launcher); intent.putExtras(bundle); startActivity(intent); in Second Acticity: Bundle bundle=this.getIntent().getExtras(); int pic=bundle.getInt("image"); v.setImageResource(pic); another method: in First Activity: Drawable drawable=imgv.getDrawable(); Bitmap bitmap= ((BitmapDrawable)drawable).getBitmap(); ByteArrayOutputStream baos = new ByteArrayOutputStream(); bitmap.compress(Bitmap.CompressFormat.PNG, 100, baos); byte[] b = baos.toByteArray(); Intent intent=new Intent(Passimage.this,myclass.class); intent.putExtra("picture", b); startActivity(intent); in Second Acticity: Bundle extras = getIntent().getExtras(); byte[] b = extras.getByteArray("picture"); Bitmap bmp = BitmapFactory.decodeByteArray(b, 0, b.lengt

Show and Resume Android Soft-Keyboard

Code to show keyboard: InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE); imm.showSoftInput(yourEditText,InputMethodManager.SHOW_IMPLICIT); Code resume keyboard : InputMethodManager imm = (InputMethodManager)gettSystemService(Context.INPUT_METHOD_SERVICE); imm.hideSoftInputFromWindow(yourEditText.getWindowToken(), 0);