SlideShare une entreprise Scribd logo
1  sur  52
1/82
2/82
Anatomy Of AndroidAnatomy Of Android
Elements & LayoutsElements & Layouts
Android development
3/82
ContentContent
INTRO1
USER INTERFACE
2
3
ANATOMY OF AN APPLICATION
4/82
Intro |Intro | quick startquick start
• Android SDK (Software Development Kit)
• JDK
• ADT (Android Development Tools, Eclipse IDE plug-in)
5/82
Intro | platform overviewIntro | platform overview
6/82
Intro | platform overviewIntro | platform overview
7/82
Intro | platform overviewIntro | platform overview
• Dalvik VM
o optimised to run on slow-cpu, low-ram, low-power devices
o runs .dex files (not .class/.jar)
o Multiple instances of DVM can run in parallel
8/82
Intro | dvm vs. jvmIntro | dvm vs. jvm
• register-based vs. stack-based
o register-based VMs allow for faster execution times, but
o programs are larger when compiled.
• execution environment - multiple vs. single instance
9/82
Intro |Intro | java vs. android apijava vs. android api
• Since it uses Java compiler, it implicitly supports a set of
Java commands
• Compatible with Java SE5 code
• A subset of Apache Harmony (open source, free Java
implementation)
• Multithreading as time-slicng.
• Dalvik implements the keyword synchronized and
java.util.concurrent.* package
• Supports reflexion and finalizers but these are not
recomended
• Does not support
o awt, swing, rmi, applet, ...
10/82
INTRO1
USER INTERFACE
2
3
6
ANATOMY OF AN APPLICATION
11/82
Apps | activityApps | activity
• Base class mostly for visual components
o extends Activity
o override onCreate
12/82
Apps | activityApps | activity
/* Example.java */
package uk.ac.ic.doc;
import android.app.Activity;
import android.os.Bundle;
public class Example extends Activity {
@Override
public void onCreate(Bundle icicle) {
super.onCreate(icicle);
setContentView(R.layout.interface);
}
}
13/82
Apps | activityApps | activity
.<?xml version=“1.0” encoding=“utf-8”?>
<LinearLayout
xmlns:android=“http://schemas.android.com/apk/res/android”
android:orientation=“vertical”
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”>
<TextView
android:id=“@+id/componentName”
android:layout_width=“fill_parent”
android:layout_height=“wrap_content”
android:text=“Text that will be displayed.”
/>
</LinearLayout>
14/82
Apps | activityApps | activity
/* Example.java */
package uk.ac.ic.doc;
import android.app.Activity;
import android.os.Bundle;
public class Example extends Activity {
@Override
public void onCreate(Bundle icicle) {
super.onCreate(icicle);
setContentView(R.layout.interface);
TextView text_view = (TextView)findViewById(R.id.componentName);
}
}
15/82
Apps | activityApps | activity
/* strings.xml */
<?xml version=“1.0” encoding=“utf-8”?>
<resources xmlns:android=“http://schemas.android.com/apk/res/android”>
<string name=“textRefName”>Text that will be displayed</strings>
</resources>
/* interface.xml */
[...]
<TextView
android:id=“@+id/componentName”
android:layout_width=“fill_parent”
android:layout_height=“wrap_content”
android:text=“@string/textRefName”
/>
16/82
Apps | activityApps | activity
17/82
Apps | activityApps | activity
@Override
protected void onSaveInstanceState(Bundle outState) {
super.onSaveInstanceState(outState);
outState.putString(“key”, value);
outState.putFloatArray(“key2”, value2);
}
@Override
public void onRestoreInstanceState(Bundle savedInstanceState) {
super.onRestoreInstanceState(savedInstanceState);
value = savedInstanceState.getString(“key”);
value2 = savedInstanceState.getFloatArray(“key2”);
}
18/82
Apps | intentApps | intent
• Allows communication between components
o Message passing
o Bundle
Intent intent = new Intent(CurrentActivity.this, OtherActivity.class);
startActivity(intent);
19/82
Apps | intentApps | intent
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
// Button listener
Button btnStart = (Button) findViewById(R.id.btn_start);
btnStart.setOnClickListener(new View.OnClickListener() {
public void onClick(View view) {
Intent intent =
new Intent(CurrentActivity.this, OtherActivity.class);
startActivity(intent);
}
});
}
20/82
Apps | threadApps | thread
Button btnPlay = (Button) findViewById(R.id.btnPlay);
btnPlay.setOnClickListener(new View.OnClickListener() {
public void onClick(View view){
// Main Thread blocks
Thread backgroundMusicThread = new Thread(
new Runnable() {
public void run() {
playMusic();
}
}
);
backgroundMusicThread.start();
}
});
21/82
Apps | hApps | handlerandler
• Communication between tasks running in parallel
22/82
Apps | hApps | handlerandlerprivate Handler mHandler = new Handler();
private Color mColor = Color.BLACK;
private Runnable mRefresh = new Runnable() {
public void run() {
mTextViewOnUI.setBackgroundColor(mColor)
}};
private Thread mCompute = new Thread(Runnable() {
public void run() {
while(1){
mColor = cpuIntensiveColorComputation(...);
mHandler.post(mRefresh);
}
}});
public void onCreate(Bundle savedInstanceState) {
mCompute.start();
}
23/82
Apps | serviceApps | service
• Base class for background tasks
o extends Service
o override onCreate
• It’s not
o a separate process
o a separate thread
• It is
o part of the main thread
o a way to update an application when it’s not active
24/82
Apps | sApps | serviceervice
25/82
Apps | bApps | broadcastroadcast rreceivereceiver
• extends BroadcastReceiver
• implements onReceive()
• Waits for a system broadcast to happen to trigger an event
• OS-generated
o Battery empty
o Camera button pressed
o New app installed
o Wifi connection established
• User-generated
o Start of some calculation
o End of an operation
26/82
Apps | bApps | broadcastroadcast rreceivereceiver
public class BRExample extends BroadcastReceiver {
@Override
public void onReceive(Context rcvCtx, Intent rcvIntent) {
if (rcvIntent.getAction().equals(Intent.ACTION_CAMERA_BUTTON)) {
rcvCtx.startService(new Intent(rcvCtx, SomeService.class));
}}}
public class SomeService extends Service {
@Override
public IBinder onBind(Intent arg0) { return null; }
@Override
public void onCreate() {
super.onCreate();
Toast.makeText(this,“Camera...”, Toast.LENGTH_LONG).show();}
@Override
public void onDestroy() {
super.onDestroy();
Toast.makeText(this, “Service done”, Toast.LENGTH_LONG).show();}
}
27/82
Apps | notificationsApps | notifications
• Toast
• AlertDialog
• Notification
Toast.makeText(this, “Notification text”, Toast.LENGTH_SHORT).show();
28/82
Apps | manifestApps | manifest
<?xml version=“1.0” encoding=“utf-8”?>
<manifest xmlns:android=“http://schemas.android.com/apk/res/android”
package=“uk.ac.ic.doc” android:versionCode=“1”
android:versionName=“1.0”>
<application android:icon=“@drawable/icon”
android:label=“@string/app_name”>
<activity android:name=“.SampleActivity”
android:label=“@string/activity_title_text_ref”>
<intent-filter>
/* ... */
</intent-filter>
</activity>
</application>
<uses-sdk android:minSdkVersion=“3” />
</manifest>
29/82
Apps | resourcesApps | resources
• /res
o anim
o drawable
• hdpi
• mdpi
• ldpi
o layout
o values
• arrays.xml
• colors.xml
• strings.xml
o xml
o raw
30/82
Apps |Apps | RR.java.java
• Autogenerated, best if not manually edited
• gen/
31/82
4
INTRO1
USER INTERFACE
2
3
ANATOMY OF AN APPLICATION
32/82
Elements and layoutsElements and layouts
• dip vs. px
• Component dimesions
o wrap_content
o fill_parent
33/82
Elements and layoutsElements and layouts
• Linear Layout
o Shows nested View elements
/* linear.xml */
<?xml version=“1.0” encoding=“utf-8”?>
<LinearLayout android:orientation=“horizontal”
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”
android:layout_weight=“1”>
<TextView android:text=“red” />
<TextView android:text=“green” />
</LinearLayout>
<LinearLayout android:orientation=“vertical”
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”
android:layout_weight=“1”>
<TextView android:text=“row one” />
</LinearLayout>
34/82
Elements and layoutsElements and layouts
• Relative Layout
35/82
Elements and layoutsElements and layouts
• Table Layout
o Like the HTML div tag
/* table.xml */
<?xml version=“1.0” encoding=“utf-8”?>
<TableLayout android:layout_width=“fill_parent”
android:layout_height=“fill_parent”
android:stretchColumns=“1”>
<TableRow>
<TextView android:layout_column=“1”
android:text=“Open...”
android:padding=“3dip” />
<TextView android:text=“Ctrl-O”
android:gravity=“right”
android:padding=“3dip” />
</TableRow>
</TableLayout>
36/82
Elements and layoutsElements and layouts
• Grid View
/* grid.xml */
<?xml version=“1.0” encoding=“utf-8”?>
<GridView
android:id=“@+id/gridview”
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”
android:columnWidth=“90dp”
android:numColumns=“auto_fit”
android:verticalSpacing=“10dp”
android:horizontalSpacing=“10dp”
android:stretchMode=“columnWidth”
android:gravity=“center”
/>
37/82
Elements and layoutsElements and layouts
• Grid View
/* GridExample.java */
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.grid);
GridView gridview = (GridView) findViewById(R.id.gridview); gridview.setAdapter(new
AdapterForGridView(this));
gridview.setOnItemClickListener(
new OnItemClickListener() {
public void onItemClick(AdapterView<?> parent, View v,
int pos, long id) {
Toast.makeText(
GridPrimer.this, "" + pos, Toast.LENGTH_SHORT).show();
}});
}
38/82
Elements and layoutsElements and layouts
• Grid View
/* AdapterForGridView.java */
public class AdapterForGridView extends BaseAdapter {
private Context mContext;
public AdapterForGridView(Context c) { mContext = c; }
public int getCount() { return mThumbIDs.length; }
public Object getItem(int position) { return null;}
public long getItemId(int position) { return 0; }
// bad getView implementation
public View getView(int pos, View convertView, ViewGroup parent) {
ImageView imageView = new ImageView(mContext);
imageView.setImageResource(mThumbIDs[pos]);
return imageView;
}
private Integer[] mThumbIDs =
{ R.drawable.img1, R.drawable.img2 /*...*/ };
}
39/82
Elements and layoutsElements and layouts
• Tab Layout
/* tab.xml */
<?xml version=“1.0” encoding=“utf-8”?>
<TabHost android:id=“@android:id/tabhost”
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”>
<LinearLayout android:orientation=“vertical”
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”>
<TabWidget android:id=“@android:id/tabs”
android:layout_width=“fill_parent”
android:layout_height=“wrap_content”/>
<FrameLayout
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”/>
</LinearLayout>
</TabHost>
40/82
Elements and layoutsElements and layouts
• Tab Layout
/* selector1.xml */
<?xml version=“1.0” encoding=“utf-8”?>
<selector xmlns:android=“http://schemas.android.com/apk/res/android”>
<!– Tab is selected -->
<item android:drawable=“@drawable/ic_tab_1_selected”
android:state_selected=“true” />
<!– Tab not selected -->
<item android:drawable=“@drawable/ic_tab_1_not_selected” />
</selector>
/* selector2.xml */
/* selector3.xml */
41/82
Elements and layoutsElements and layouts
• Tab Layout
/* Tab1.java */
public class Tab1 extends Activity {
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
TextView textview = new TextView(this);
textview.setText(“This is the Artists tab”);
setContentView(textview);
}
}
/* Tab2.java */
/* Tab3.java */
42/82
Elements and layoutsElements and layouts
• Tab Layout
/* TabExample.java */
public class TabExample extends TabActivity {
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.tab);
TabHost tabHost = getTabHost();
//--- tab 1 ---
Intent intent = new Intent().setClass(this, Tab1.class);
TabHost.TabSpec spec = tabHost.newTabSpec(“tab1”).setIndicator(
“Artists”, getResources().getDrawable(R.drawable.selector1))
.setContent(intent);
tabHost.addTab(spec); //--- tab 1 ---
tabHost.setCurrentTab(2);}
43/82
Elements and layoutsElements and layouts
• List View
/* list_item.xml */
<?xml version=“1.0” encoding=“utf-8”?>
<TextView
android:layout_width=“fill_parent”
android:layout_height=“fill_parent”
android:padding=“10dp”
android:textSize=“16sp” />
44/82
Elements and layoutsElements and layouts
• List View
/* ListViewExample.java */
public class ListViewExample extends ListActivity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setListAdapter(new ArrayAdapter<String>(this,
R.layout.list_item, COUNTRIES));
ListView lv = getListView();
lv.setTextFilterEnabled(true);
lv.setOnItemClickListener(new OnItemClickListener() {
public void onItemClick(AdapterView<?> parent, View view,
int position, long id) {
Toast.makeText(getApplicationContext(),
((TextView) view).getText(), Toast.LENGTH_SHORT).show();
}});
}
45/82
Elements and layoutsElements and layouts
• Button
• ImageButton
• EditText
• CheckBox
• RadioButton
• ToggleButton
• RatingBar
46/82
Elements and layoutsElements and layouts
• DatePicker
• TimePicker
• Spinner
• AutoComplete
• Gallery
• MapView
• WebView
47/82
EventsEvents
• Event Handler
o Hardware buttons
• Event Listener
o Touch screen
48/82
EventsEvents
• KeyEvent is sent to callback methods
o onKeyUp(), onKeyDown(), onKeyLongpress()
o onTrackballEvent(), onTouchEvent()
public boolean onKeyDown(int keyCode, KeyEvent event) {
if (keyCode == KeyEvent.KEYCODE_CAMERA) {
return true; // consumes the event
}
return super.onKeyDown(keyCode, event);
}
Button button = (Button) findViewById(R.id.button);
button.setOnClickListener(new View.OnClickListener() {
public void onClick(View view) { /* ... */ }
});
49/82
EventsEvents
public class TouchExample extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
Button button = (Button) findViewById(R.id.button);
button.setOnClickListener(new OnClickListener() {
public void onClick(View v) { /*...*/ }
});
button.setOnLongClickListener(new OnLongClickListener() {
public boolean onLongClick(View v) {
// ...
return true;
}
});}}
50/82
MenusMenus
• Options Menu: MENU button, tied to an Activity
• Context Menu: View LongPress
• Submenu
public boolean onCreateOptionsMenu(Menu menu) {
menu.add(0, MENU_ADD, 0, “Add”)
.setIcon(R.drawable.icon);
menu.add(0, MENU_WALLPAPER, 0, “Wallpaper”);
return super.onCreateOptionsMenu(menu);
}
public boolean onOptionsItemSelected(MenuItem item) {
switch(item.getItemId()) {
case MENU_ADD: //... ; return true;
case MENU_WALLPAPER: //... ; return true;
default: return false;}}
51/82
WidgetWidget
• XML Layout
• AppWidgetProvider gets notified
• Dimensions and refresh frequency
52/82
ThankThank You !!!You !!!
For More Information click below link:
Follow Us on:
http://vibranttechnologies.co.in/android-classes-in-mumbai.html

Contenu connexe

Tendances

Virus Bulletin 2015: Exposing Gatekeeper
Virus Bulletin 2015: Exposing GatekeeperVirus Bulletin 2015: Exposing Gatekeeper
Virus Bulletin 2015: Exposing GatekeeperSynack
 
Mastering the NDK with Android Studio 2.0 and the gradle-experimental plugin
Mastering the NDK with Android Studio 2.0 and the gradle-experimental pluginMastering the NDK with Android Studio 2.0 and the gradle-experimental plugin
Mastering the NDK with Android Studio 2.0 and the gradle-experimental pluginXavier Hallade
 
[1D6]RE-view of Android L developer PRE-view
[1D6]RE-view of Android L developer PRE-view[1D6]RE-view of Android L developer PRE-view
[1D6]RE-view of Android L developer PRE-viewNAVER D2
 
Android programming -_pushing_the_limits
Android programming -_pushing_the_limitsAndroid programming -_pushing_the_limits
Android programming -_pushing_the_limitsDroidcon Berlin
 
SgCodeJam24 Workshop
SgCodeJam24 WorkshopSgCodeJam24 Workshop
SgCodeJam24 Workshopremko caprio
 
Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016
Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016
Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016Christian Schneider
 
Multithreading in Android
Multithreading in AndroidMultithreading in Android
Multithreading in Androidcoolmirza143
 
Building Microservices with Helidon: Oracle's New Java Microservices Framework
Building Microservices with Helidon:  Oracle's New Java Microservices FrameworkBuilding Microservices with Helidon:  Oracle's New Java Microservices Framework
Building Microservices with Helidon: Oracle's New Java Microservices FrameworkMichael Redlich
 
CDI e as ideias pro futuro do VRaptor
CDI e as ideias pro futuro do VRaptorCDI e as ideias pro futuro do VRaptor
CDI e as ideias pro futuro do VRaptorCaelum
 
Synack at AppSec California 2015 - Geolocation Vulnerabilities
Synack at AppSec California 2015 - Geolocation VulnerabilitiesSynack at AppSec California 2015 - Geolocation Vulnerabilities
Synack at AppSec California 2015 - Geolocation VulnerabilitiesSynack
 
Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)DroidConTLV
 

Tendances (13)

Virus Bulletin 2015: Exposing Gatekeeper
Virus Bulletin 2015: Exposing GatekeeperVirus Bulletin 2015: Exposing Gatekeeper
Virus Bulletin 2015: Exposing Gatekeeper
 
Mastering the NDK with Android Studio 2.0 and the gradle-experimental plugin
Mastering the NDK with Android Studio 2.0 and the gradle-experimental pluginMastering the NDK with Android Studio 2.0 and the gradle-experimental plugin
Mastering the NDK with Android Studio 2.0 and the gradle-experimental plugin
 
[1D6]RE-view of Android L developer PRE-view
[1D6]RE-view of Android L developer PRE-view[1D6]RE-view of Android L developer PRE-view
[1D6]RE-view of Android L developer PRE-view
 
droidparts
droidpartsdroidparts
droidparts
 
Android programming -_pushing_the_limits
Android programming -_pushing_the_limitsAndroid programming -_pushing_the_limits
Android programming -_pushing_the_limits
 
SgCodeJam24 Workshop
SgCodeJam24 WorkshopSgCodeJam24 Workshop
SgCodeJam24 Workshop
 
Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016
Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016
Serial Killer - Silently Pwning your Java Endpoints // OWASP BeNeLux Day 2016
 
Multithreading in Android
Multithreading in AndroidMultithreading in Android
Multithreading in Android
 
Building Microservices with Helidon: Oracle's New Java Microservices Framework
Building Microservices with Helidon:  Oracle's New Java Microservices FrameworkBuilding Microservices with Helidon:  Oracle's New Java Microservices Framework
Building Microservices with Helidon: Oracle's New Java Microservices Framework
 
CDI e as ideias pro futuro do VRaptor
CDI e as ideias pro futuro do VRaptorCDI e as ideias pro futuro do VRaptor
CDI e as ideias pro futuro do VRaptor
 
Synack at AppSec California 2015 - Geolocation Vulnerabilities
Synack at AppSec California 2015 - Geolocation VulnerabilitiesSynack at AppSec California 2015 - Geolocation Vulnerabilities
Synack at AppSec California 2015 - Geolocation Vulnerabilities
 
Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)
 
Android ndk
Android ndkAndroid ndk
Android ndk
 

En vedette

Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...
Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...
Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...Anne Nicolas
 
From Android NDK To AOSP
From Android NDK To AOSPFrom Android NDK To AOSP
From Android NDK To AOSPMin-Yih Hsu
 
Android binding framework
Android binding frameworkAndroid binding framework
Android binding framework동우 김
 
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generator
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generatorKernel Recipes 2013 - Crosstool-NG, a cross-toolchain generator
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generatorAnne Nicolas
 
Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...
Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...
Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...Anne Nicolas
 
Kernel Recipes 2013 - Persistent logs using UBI
Kernel Recipes 2013 - Persistent logs using UBIKernel Recipes 2013 - Persistent logs using UBI
Kernel Recipes 2013 - Persistent logs using UBIAnne Nicolas
 
Kernel Recipes 2013 - ARM support in the Linux kernel
Kernel Recipes 2013 - ARM support in the Linux kernelKernel Recipes 2013 - ARM support in the Linux kernel
Kernel Recipes 2013 - ARM support in the Linux kernelAnne Nicolas
 
Browsing Linux Kernel Source
Browsing Linux Kernel SourceBrowsing Linux Kernel Source
Browsing Linux Kernel SourceMotaz Saad
 
An Introduction to the Android Framework -- a core architecture view from app...
An Introduction to the Android Framework -- a core architecture view from app...An Introduction to the Android Framework -- a core architecture view from app...
An Introduction to the Android Framework -- a core architecture view from app...William Liang
 
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)Nanik Tolaram
 
Overview of Android binder IPC implementation
Overview of Android binder IPC implementationOverview of Android binder IPC implementation
Overview of Android binder IPC implementationChethan Pchethan
 
Android IPC Mechanism
Android IPC MechanismAndroid IPC Mechanism
Android IPC MechanismLihan Chen
 
COSCUP 開源工作坊:Git workflows
COSCUP 開源工作坊:Git workflowsCOSCUP 開源工作坊:Git workflows
COSCUP 開源工作坊:Git workflowsCarl Su
 
Linux Kernel and Driver Development Training
Linux Kernel and Driver Development TrainingLinux Kernel and Driver Development Training
Linux Kernel and Driver Development TrainingStephan Cadene
 
Android device driver structure introduction
Android device driver structure introductionAndroid device driver structure introduction
Android device driver structure introductionWilliam Liang
 
作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...
作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...
作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...William Liang
 
Linux kernel tracing
Linux kernel tracingLinux kernel tracing
Linux kernel tracingViller Hsiao
 
嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...
嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...
嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...William Liang
 

En vedette (20)

Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...
Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...
Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...
 
From Android NDK To AOSP
From Android NDK To AOSPFrom Android NDK To AOSP
From Android NDK To AOSP
 
Android binding framework
Android binding frameworkAndroid binding framework
Android binding framework
 
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generator
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generatorKernel Recipes 2013 - Crosstool-NG, a cross-toolchain generator
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generator
 
Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...
Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...
Kernel Recipes 2013 - kconfig-frontends, a packaging of the kconfig parser an...
 
Kernel Recipes 2013 - Persistent logs using UBI
Kernel Recipes 2013 - Persistent logs using UBIKernel Recipes 2013 - Persistent logs using UBI
Kernel Recipes 2013 - Persistent logs using UBI
 
Kernel Recipes 2013 - ARM support in the Linux kernel
Kernel Recipes 2013 - ARM support in the Linux kernelKernel Recipes 2013 - ARM support in the Linux kernel
Kernel Recipes 2013 - ARM support in the Linux kernel
 
Browsing Linux Kernel Source
Browsing Linux Kernel SourceBrowsing Linux Kernel Source
Browsing Linux Kernel Source
 
An Introduction to the Android Framework -- a core architecture view from app...
An Introduction to the Android Framework -- a core architecture view from app...An Introduction to the Android Framework -- a core architecture view from app...
An Introduction to the Android Framework -- a core architecture view from app...
 
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
 
Overview of Android binder IPC implementation
Overview of Android binder IPC implementationOverview of Android binder IPC implementation
Overview of Android binder IPC implementation
 
Android IPC Mechanism
Android IPC MechanismAndroid IPC Mechanism
Android IPC Mechanism
 
Android IPC Mechanism
Android IPC MechanismAndroid IPC Mechanism
Android IPC Mechanism
 
COSCUP 開源工作坊:Git workflows
COSCUP 開源工作坊:Git workflowsCOSCUP 開源工作坊:Git workflows
COSCUP 開源工作坊:Git workflows
 
Linux Kernel and Driver Development Training
Linux Kernel and Driver Development TrainingLinux Kernel and Driver Development Training
Linux Kernel and Driver Development Training
 
Android device driver structure introduction
Android device driver structure introductionAndroid device driver structure introduction
Android device driver structure introduction
 
作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...
作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...
作業系統與硬體元件的驅動軟體開發法則 (Operating Systems and Software Design Principles for Har...
 
Linux kernel tracing
Linux kernel tracingLinux kernel tracing
Linux kernel tracing
 
嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...
嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...
嵌入式智慧應用開源軟硬整合新趨勢 (Open Source Software and Hardware Integration Trend for Emb...
 
Architecture Of The Linux Kernel
Architecture Of The Linux KernelArchitecture Of The Linux Kernel
Architecture Of The Linux Kernel
 

Similaire à ANATOMY OF ANDROID

Android tutorial (2)
Android tutorial (2)Android tutorial (2)
Android tutorial (2)Kumar
 
Android Best Practices
Android Best PracticesAndroid Best Practices
Android Best PracticesYekmer Simsek
 
Suportando Aplicações Multi-tenancy com Java EE
Suportando Aplicações Multi-tenancy com Java EESuportando Aplicações Multi-tenancy com Java EE
Suportando Aplicações Multi-tenancy com Java EERodrigo Cândido da Silva
 
Androidaop 170105090257
Androidaop 170105090257Androidaop 170105090257
Androidaop 170105090257newegg
 
"JavaME + Android in action" CCT-CEJUG Dezembro 2008
"JavaME + Android in action" CCT-CEJUG Dezembro 2008"JavaME + Android in action" CCT-CEJUG Dezembro 2008
"JavaME + Android in action" CCT-CEJUG Dezembro 2008Vando Batista
 
Asynchronous Module Definition (AMD)
Asynchronous Module Definition (AMD)Asynchronous Module Definition (AMD)
Asynchronous Module Definition (AMD)xMartin12
 
Creating a Java Internet of Things Gateway
Creating a Java Internet of Things GatewayCreating a Java Internet of Things Gateway
Creating a Java Internet of Things GatewayEurotech
 
Overview of Android Infrastructure
Overview of Android InfrastructureOverview of Android Infrastructure
Overview of Android InfrastructureAlexey Buzdin
 
Overview of Android Infrastructure
Overview of Android InfrastructureOverview of Android Infrastructure
Overview of Android InfrastructureC.T.Co
 
ITT 2014 - Peter Steinberger - Architecting Modular Codebases
ITT 2014 - Peter Steinberger - Architecting Modular CodebasesITT 2014 - Peter Steinberger - Architecting Modular Codebases
ITT 2014 - Peter Steinberger - Architecting Modular CodebasesIstanbul Tech Talks
 
Android Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NC
Android Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NCAndroid Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NC
Android Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NCJim Tochterman
 
How to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita GalkinHow to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita GalkinSigma Software
 
Divide and Conquer – Microservices with Node.js
Divide and Conquer – Microservices with Node.jsDivide and Conquer – Microservices with Node.js
Divide and Conquer – Microservices with Node.jsSebastian Springer
 
02 hello world - Android
02   hello world - Android02   hello world - Android
02 hello world - AndroidWingston
 
Quick Intro to Android Development
Quick Intro to Android DevelopmentQuick Intro to Android Development
Quick Intro to Android DevelopmentJussi Pohjolainen
 

Similaire à ANATOMY OF ANDROID (20)

Android tutorial (2)
Android tutorial (2)Android tutorial (2)
Android tutorial (2)
 
Android classes in mumbai
Android classes in mumbaiAndroid classes in mumbai
Android classes in mumbai
 
Android - Api & Debugging in Android
Android - Api & Debugging in AndroidAndroid - Api & Debugging in Android
Android - Api & Debugging in Android
 
Android Best Practices
Android Best PracticesAndroid Best Practices
Android Best Practices
 
Ruby conf2012
Ruby conf2012Ruby conf2012
Ruby conf2012
 
Suportando Aplicações Multi-tenancy com Java EE
Suportando Aplicações Multi-tenancy com Java EESuportando Aplicações Multi-tenancy com Java EE
Suportando Aplicações Multi-tenancy com Java EE
 
Android basics
Android basicsAndroid basics
Android basics
 
Androidaop 170105090257
Androidaop 170105090257Androidaop 170105090257
Androidaop 170105090257
 
"JavaME + Android in action" CCT-CEJUG Dezembro 2008
"JavaME + Android in action" CCT-CEJUG Dezembro 2008"JavaME + Android in action" CCT-CEJUG Dezembro 2008
"JavaME + Android in action" CCT-CEJUG Dezembro 2008
 
Asynchronous Module Definition (AMD)
Asynchronous Module Definition (AMD)Asynchronous Module Definition (AMD)
Asynchronous Module Definition (AMD)
 
Creating a Java Internet of Things Gateway
Creating a Java Internet of Things GatewayCreating a Java Internet of Things Gateway
Creating a Java Internet of Things Gateway
 
Overview of Android Infrastructure
Overview of Android InfrastructureOverview of Android Infrastructure
Overview of Android Infrastructure
 
Overview of Android Infrastructure
Overview of Android InfrastructureOverview of Android Infrastructure
Overview of Android Infrastructure
 
ITT 2014 - Peter Steinberger - Architecting Modular Codebases
ITT 2014 - Peter Steinberger - Architecting Modular CodebasesITT 2014 - Peter Steinberger - Architecting Modular Codebases
ITT 2014 - Peter Steinberger - Architecting Modular Codebases
 
Android Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NC
Android Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NCAndroid Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NC
Android Development w/ ArcGIS Server - Esri Dev Meetup - Charlotte, NC
 
How to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita GalkinHow to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita Galkin
 
Divide and Conquer – Microservices with Node.js
Divide and Conquer – Microservices with Node.jsDivide and Conquer – Microservices with Node.js
Divide and Conquer – Microservices with Node.js
 
02 hello world - Android
02   hello world - Android02   hello world - Android
02 hello world - Android
 
Quick Intro to Android Development
Quick Intro to Android DevelopmentQuick Intro to Android Development
Quick Intro to Android Development
 
Mini curso Android
Mini curso AndroidMini curso Android
Mini curso Android
 

Plus de Vibrant Technologies & Computers

Data ware housing - Introduction to data ware housing process.
Data ware housing - Introduction to data ware housing process.Data ware housing - Introduction to data ware housing process.
Data ware housing - Introduction to data ware housing process.Vibrant Technologies & Computers
 

Plus de Vibrant Technologies & Computers (20)

Buisness analyst business analysis overview ppt 5
Buisness analyst business analysis overview ppt 5Buisness analyst business analysis overview ppt 5
Buisness analyst business analysis overview ppt 5
 
SQL Introduction to displaying data from multiple tables
SQL Introduction to displaying data from multiple tables  SQL Introduction to displaying data from multiple tables
SQL Introduction to displaying data from multiple tables
 
SQL- Introduction to MySQL
SQL- Introduction to MySQLSQL- Introduction to MySQL
SQL- Introduction to MySQL
 
SQL- Introduction to SQL database
SQL- Introduction to SQL database SQL- Introduction to SQL database
SQL- Introduction to SQL database
 
ITIL - introduction to ITIL
ITIL - introduction to ITILITIL - introduction to ITIL
ITIL - introduction to ITIL
 
Salesforce - Introduction to Security & Access
Salesforce -  Introduction to Security & Access Salesforce -  Introduction to Security & Access
Salesforce - Introduction to Security & Access
 
Data ware housing- Introduction to olap .
Data ware housing- Introduction to  olap .Data ware housing- Introduction to  olap .
Data ware housing- Introduction to olap .
 
Data ware housing - Introduction to data ware housing process.
Data ware housing - Introduction to data ware housing process.Data ware housing - Introduction to data ware housing process.
Data ware housing - Introduction to data ware housing process.
 
Data ware housing- Introduction to data ware housing
Data ware housing- Introduction to data ware housingData ware housing- Introduction to data ware housing
Data ware housing- Introduction to data ware housing
 
Salesforce - classification of cloud computing
Salesforce - classification of cloud computingSalesforce - classification of cloud computing
Salesforce - classification of cloud computing
 
Salesforce - cloud computing fundamental
Salesforce - cloud computing fundamentalSalesforce - cloud computing fundamental
Salesforce - cloud computing fundamental
 
SQL- Introduction to PL/SQL
SQL- Introduction to  PL/SQLSQL- Introduction to  PL/SQL
SQL- Introduction to PL/SQL
 
SQL- Introduction to advanced sql concepts
SQL- Introduction to  advanced sql conceptsSQL- Introduction to  advanced sql concepts
SQL- Introduction to advanced sql concepts
 
SQL Inteoduction to SQL manipulating of data
SQL Inteoduction to SQL manipulating of data   SQL Inteoduction to SQL manipulating of data
SQL Inteoduction to SQL manipulating of data
 
SQL- Introduction to SQL Set Operations
SQL- Introduction to SQL Set OperationsSQL- Introduction to SQL Set Operations
SQL- Introduction to SQL Set Operations
 
Sas - Introduction to designing the data mart
Sas - Introduction to designing the data martSas - Introduction to designing the data mart
Sas - Introduction to designing the data mart
 
Sas - Introduction to working under change management
Sas - Introduction to working under change managementSas - Introduction to working under change management
Sas - Introduction to working under change management
 
SAS - overview of SAS
SAS - overview of SASSAS - overview of SAS
SAS - overview of SAS
 
Teradata - Architecture of Teradata
Teradata - Architecture of TeradataTeradata - Architecture of Teradata
Teradata - Architecture of Teradata
 
Teradata - Restoring Data
Teradata - Restoring Data Teradata - Restoring Data
Teradata - Restoring Data
 

Dernier

Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 

Dernier (20)

Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 

ANATOMY OF ANDROID

  • 2. 2/82 Anatomy Of AndroidAnatomy Of Android Elements & LayoutsElements & Layouts Android development
  • 4. 4/82 Intro |Intro | quick startquick start • Android SDK (Software Development Kit) • JDK • ADT (Android Development Tools, Eclipse IDE plug-in)
  • 5. 5/82 Intro | platform overviewIntro | platform overview
  • 6. 6/82 Intro | platform overviewIntro | platform overview
  • 7. 7/82 Intro | platform overviewIntro | platform overview • Dalvik VM o optimised to run on slow-cpu, low-ram, low-power devices o runs .dex files (not .class/.jar) o Multiple instances of DVM can run in parallel
  • 8. 8/82 Intro | dvm vs. jvmIntro | dvm vs. jvm • register-based vs. stack-based o register-based VMs allow for faster execution times, but o programs are larger when compiled. • execution environment - multiple vs. single instance
  • 9. 9/82 Intro |Intro | java vs. android apijava vs. android api • Since it uses Java compiler, it implicitly supports a set of Java commands • Compatible with Java SE5 code • A subset of Apache Harmony (open source, free Java implementation) • Multithreading as time-slicng. • Dalvik implements the keyword synchronized and java.util.concurrent.* package • Supports reflexion and finalizers but these are not recomended • Does not support o awt, swing, rmi, applet, ...
  • 11. 11/82 Apps | activityApps | activity • Base class mostly for visual components o extends Activity o override onCreate
  • 12. 12/82 Apps | activityApps | activity /* Example.java */ package uk.ac.ic.doc; import android.app.Activity; import android.os.Bundle; public class Example extends Activity { @Override public void onCreate(Bundle icicle) { super.onCreate(icicle); setContentView(R.layout.interface); } }
  • 13. 13/82 Apps | activityApps | activity .<?xml version=“1.0” encoding=“utf-8”?> <LinearLayout xmlns:android=“http://schemas.android.com/apk/res/android” android:orientation=“vertical” android:layout_width=“fill_parent” android:layout_height=“fill_parent”> <TextView android:id=“@+id/componentName” android:layout_width=“fill_parent” android:layout_height=“wrap_content” android:text=“Text that will be displayed.” /> </LinearLayout>
  • 14. 14/82 Apps | activityApps | activity /* Example.java */ package uk.ac.ic.doc; import android.app.Activity; import android.os.Bundle; public class Example extends Activity { @Override public void onCreate(Bundle icicle) { super.onCreate(icicle); setContentView(R.layout.interface); TextView text_view = (TextView)findViewById(R.id.componentName); } }
  • 15. 15/82 Apps | activityApps | activity /* strings.xml */ <?xml version=“1.0” encoding=“utf-8”?> <resources xmlns:android=“http://schemas.android.com/apk/res/android”> <string name=“textRefName”>Text that will be displayed</strings> </resources> /* interface.xml */ [...] <TextView android:id=“@+id/componentName” android:layout_width=“fill_parent” android:layout_height=“wrap_content” android:text=“@string/textRefName” />
  • 17. 17/82 Apps | activityApps | activity @Override protected void onSaveInstanceState(Bundle outState) { super.onSaveInstanceState(outState); outState.putString(“key”, value); outState.putFloatArray(“key2”, value2); } @Override public void onRestoreInstanceState(Bundle savedInstanceState) { super.onRestoreInstanceState(savedInstanceState); value = savedInstanceState.getString(“key”); value2 = savedInstanceState.getFloatArray(“key2”); }
  • 18. 18/82 Apps | intentApps | intent • Allows communication between components o Message passing o Bundle Intent intent = new Intent(CurrentActivity.this, OtherActivity.class); startActivity(intent);
  • 19. 19/82 Apps | intentApps | intent @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); // Button listener Button btnStart = (Button) findViewById(R.id.btn_start); btnStart.setOnClickListener(new View.OnClickListener() { public void onClick(View view) { Intent intent = new Intent(CurrentActivity.this, OtherActivity.class); startActivity(intent); } }); }
  • 20. 20/82 Apps | threadApps | thread Button btnPlay = (Button) findViewById(R.id.btnPlay); btnPlay.setOnClickListener(new View.OnClickListener() { public void onClick(View view){ // Main Thread blocks Thread backgroundMusicThread = new Thread( new Runnable() { public void run() { playMusic(); } } ); backgroundMusicThread.start(); } });
  • 21. 21/82 Apps | hApps | handlerandler • Communication between tasks running in parallel
  • 22. 22/82 Apps | hApps | handlerandlerprivate Handler mHandler = new Handler(); private Color mColor = Color.BLACK; private Runnable mRefresh = new Runnable() { public void run() { mTextViewOnUI.setBackgroundColor(mColor) }}; private Thread mCompute = new Thread(Runnable() { public void run() { while(1){ mColor = cpuIntensiveColorComputation(...); mHandler.post(mRefresh); } }}); public void onCreate(Bundle savedInstanceState) { mCompute.start(); }
  • 23. 23/82 Apps | serviceApps | service • Base class for background tasks o extends Service o override onCreate • It’s not o a separate process o a separate thread • It is o part of the main thread o a way to update an application when it’s not active
  • 24. 24/82 Apps | sApps | serviceervice
  • 25. 25/82 Apps | bApps | broadcastroadcast rreceivereceiver • extends BroadcastReceiver • implements onReceive() • Waits for a system broadcast to happen to trigger an event • OS-generated o Battery empty o Camera button pressed o New app installed o Wifi connection established • User-generated o Start of some calculation o End of an operation
  • 26. 26/82 Apps | bApps | broadcastroadcast rreceivereceiver public class BRExample extends BroadcastReceiver { @Override public void onReceive(Context rcvCtx, Intent rcvIntent) { if (rcvIntent.getAction().equals(Intent.ACTION_CAMERA_BUTTON)) { rcvCtx.startService(new Intent(rcvCtx, SomeService.class)); }}} public class SomeService extends Service { @Override public IBinder onBind(Intent arg0) { return null; } @Override public void onCreate() { super.onCreate(); Toast.makeText(this,“Camera...”, Toast.LENGTH_LONG).show();} @Override public void onDestroy() { super.onDestroy(); Toast.makeText(this, “Service done”, Toast.LENGTH_LONG).show();} }
  • 27. 27/82 Apps | notificationsApps | notifications • Toast • AlertDialog • Notification Toast.makeText(this, “Notification text”, Toast.LENGTH_SHORT).show();
  • 28. 28/82 Apps | manifestApps | manifest <?xml version=“1.0” encoding=“utf-8”?> <manifest xmlns:android=“http://schemas.android.com/apk/res/android” package=“uk.ac.ic.doc” android:versionCode=“1” android:versionName=“1.0”> <application android:icon=“@drawable/icon” android:label=“@string/app_name”> <activity android:name=“.SampleActivity” android:label=“@string/activity_title_text_ref”> <intent-filter> /* ... */ </intent-filter> </activity> </application> <uses-sdk android:minSdkVersion=“3” /> </manifest>
  • 29. 29/82 Apps | resourcesApps | resources • /res o anim o drawable • hdpi • mdpi • ldpi o layout o values • arrays.xml • colors.xml • strings.xml o xml o raw
  • 30. 30/82 Apps |Apps | RR.java.java • Autogenerated, best if not manually edited • gen/
  • 32. 32/82 Elements and layoutsElements and layouts • dip vs. px • Component dimesions o wrap_content o fill_parent
  • 33. 33/82 Elements and layoutsElements and layouts • Linear Layout o Shows nested View elements /* linear.xml */ <?xml version=“1.0” encoding=“utf-8”?> <LinearLayout android:orientation=“horizontal” android:layout_width=“fill_parent” android:layout_height=“fill_parent” android:layout_weight=“1”> <TextView android:text=“red” /> <TextView android:text=“green” /> </LinearLayout> <LinearLayout android:orientation=“vertical” android:layout_width=“fill_parent” android:layout_height=“fill_parent” android:layout_weight=“1”> <TextView android:text=“row one” /> </LinearLayout>
  • 34. 34/82 Elements and layoutsElements and layouts • Relative Layout
  • 35. 35/82 Elements and layoutsElements and layouts • Table Layout o Like the HTML div tag /* table.xml */ <?xml version=“1.0” encoding=“utf-8”?> <TableLayout android:layout_width=“fill_parent” android:layout_height=“fill_parent” android:stretchColumns=“1”> <TableRow> <TextView android:layout_column=“1” android:text=“Open...” android:padding=“3dip” /> <TextView android:text=“Ctrl-O” android:gravity=“right” android:padding=“3dip” /> </TableRow> </TableLayout>
  • 36. 36/82 Elements and layoutsElements and layouts • Grid View /* grid.xml */ <?xml version=“1.0” encoding=“utf-8”?> <GridView android:id=“@+id/gridview” android:layout_width=“fill_parent” android:layout_height=“fill_parent” android:columnWidth=“90dp” android:numColumns=“auto_fit” android:verticalSpacing=“10dp” android:horizontalSpacing=“10dp” android:stretchMode=“columnWidth” android:gravity=“center” />
  • 37. 37/82 Elements and layoutsElements and layouts • Grid View /* GridExample.java */ public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.grid); GridView gridview = (GridView) findViewById(R.id.gridview); gridview.setAdapter(new AdapterForGridView(this)); gridview.setOnItemClickListener( new OnItemClickListener() { public void onItemClick(AdapterView<?> parent, View v, int pos, long id) { Toast.makeText( GridPrimer.this, "" + pos, Toast.LENGTH_SHORT).show(); }}); }
  • 38. 38/82 Elements and layoutsElements and layouts • Grid View /* AdapterForGridView.java */ public class AdapterForGridView extends BaseAdapter { private Context mContext; public AdapterForGridView(Context c) { mContext = c; } public int getCount() { return mThumbIDs.length; } public Object getItem(int position) { return null;} public long getItemId(int position) { return 0; } // bad getView implementation public View getView(int pos, View convertView, ViewGroup parent) { ImageView imageView = new ImageView(mContext); imageView.setImageResource(mThumbIDs[pos]); return imageView; } private Integer[] mThumbIDs = { R.drawable.img1, R.drawable.img2 /*...*/ }; }
  • 39. 39/82 Elements and layoutsElements and layouts • Tab Layout /* tab.xml */ <?xml version=“1.0” encoding=“utf-8”?> <TabHost android:id=“@android:id/tabhost” android:layout_width=“fill_parent” android:layout_height=“fill_parent”> <LinearLayout android:orientation=“vertical” android:layout_width=“fill_parent” android:layout_height=“fill_parent”> <TabWidget android:id=“@android:id/tabs” android:layout_width=“fill_parent” android:layout_height=“wrap_content”/> <FrameLayout android:layout_width=“fill_parent” android:layout_height=“fill_parent”/> </LinearLayout> </TabHost>
  • 40. 40/82 Elements and layoutsElements and layouts • Tab Layout /* selector1.xml */ <?xml version=“1.0” encoding=“utf-8”?> <selector xmlns:android=“http://schemas.android.com/apk/res/android”> <!– Tab is selected --> <item android:drawable=“@drawable/ic_tab_1_selected” android:state_selected=“true” /> <!– Tab not selected --> <item android:drawable=“@drawable/ic_tab_1_not_selected” /> </selector> /* selector2.xml */ /* selector3.xml */
  • 41. 41/82 Elements and layoutsElements and layouts • Tab Layout /* Tab1.java */ public class Tab1 extends Activity { public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); TextView textview = new TextView(this); textview.setText(“This is the Artists tab”); setContentView(textview); } } /* Tab2.java */ /* Tab3.java */
  • 42. 42/82 Elements and layoutsElements and layouts • Tab Layout /* TabExample.java */ public class TabExample extends TabActivity { public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.tab); TabHost tabHost = getTabHost(); //--- tab 1 --- Intent intent = new Intent().setClass(this, Tab1.class); TabHost.TabSpec spec = tabHost.newTabSpec(“tab1”).setIndicator( “Artists”, getResources().getDrawable(R.drawable.selector1)) .setContent(intent); tabHost.addTab(spec); //--- tab 1 --- tabHost.setCurrentTab(2);}
  • 43. 43/82 Elements and layoutsElements and layouts • List View /* list_item.xml */ <?xml version=“1.0” encoding=“utf-8”?> <TextView android:layout_width=“fill_parent” android:layout_height=“fill_parent” android:padding=“10dp” android:textSize=“16sp” />
  • 44. 44/82 Elements and layoutsElements and layouts • List View /* ListViewExample.java */ public class ListViewExample extends ListActivity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setListAdapter(new ArrayAdapter<String>(this, R.layout.list_item, COUNTRIES)); ListView lv = getListView(); lv.setTextFilterEnabled(true); lv.setOnItemClickListener(new OnItemClickListener() { public void onItemClick(AdapterView<?> parent, View view, int position, long id) { Toast.makeText(getApplicationContext(), ((TextView) view).getText(), Toast.LENGTH_SHORT).show(); }}); }
  • 45. 45/82 Elements and layoutsElements and layouts • Button • ImageButton • EditText • CheckBox • RadioButton • ToggleButton • RatingBar
  • 46. 46/82 Elements and layoutsElements and layouts • DatePicker • TimePicker • Spinner • AutoComplete • Gallery • MapView • WebView
  • 47. 47/82 EventsEvents • Event Handler o Hardware buttons • Event Listener o Touch screen
  • 48. 48/82 EventsEvents • KeyEvent is sent to callback methods o onKeyUp(), onKeyDown(), onKeyLongpress() o onTrackballEvent(), onTouchEvent() public boolean onKeyDown(int keyCode, KeyEvent event) { if (keyCode == KeyEvent.KEYCODE_CAMERA) { return true; // consumes the event } return super.onKeyDown(keyCode, event); } Button button = (Button) findViewById(R.id.button); button.setOnClickListener(new View.OnClickListener() { public void onClick(View view) { /* ... */ } });
  • 49. 49/82 EventsEvents public class TouchExample extends Activity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); Button button = (Button) findViewById(R.id.button); button.setOnClickListener(new OnClickListener() { public void onClick(View v) { /*...*/ } }); button.setOnLongClickListener(new OnLongClickListener() { public boolean onLongClick(View v) { // ... return true; } });}}
  • 50. 50/82 MenusMenus • Options Menu: MENU button, tied to an Activity • Context Menu: View LongPress • Submenu public boolean onCreateOptionsMenu(Menu menu) { menu.add(0, MENU_ADD, 0, “Add”) .setIcon(R.drawable.icon); menu.add(0, MENU_WALLPAPER, 0, “Wallpaper”); return super.onCreateOptionsMenu(menu); } public boolean onOptionsItemSelected(MenuItem item) { switch(item.getItemId()) { case MENU_ADD: //... ; return true; case MENU_WALLPAPER: //... ; return true; default: return false;}}
  • 51. 51/82 WidgetWidget • XML Layout • AppWidgetProvider gets notified • Dimensions and refresh frequency
  • 52. 52/82 ThankThank You !!!You !!! For More Information click below link: Follow Us on: http://vibranttechnologies.co.in/android-classes-in-mumbai.html