Understand:
- Background of Android
- The process of Android Application
- Four main components in Android Application
- Where to store each kind of resource
2. Content
Introduction to Android
- What is Android
- Android Version
- Android Architecture
- Android Components
- Android Application Structure
Understand:
- Background of Android
- The process of Android Application
- Four main components in
Android Application
- Where to store each kind of resource
3. 1.1.What is Android?
- Android is an operating system based on the Linux kernel.
- Android is developed in the Android open Source Project (AOSP). This
project is lead by Google.
- The Android Operating system can be divided into the four areas such as
Application, Application Framework, Libraries or Runtime, Linux Kernel.
- For an Android application Developer works with Application and Application
Framework to create new Android application.
4. 1.2. Android versions
- The Android operating system is published in different versions such as
More Details: https://www.android.com/history/#/donut
6. 1.3. Android Architecture
- Applications - Contains the applications such as Browser, Camera,
Gallery, Music and Phone.
- Application framework - An API which allows high-level interactions
with the Android system.
- Libraries and runtime - The libraries for many common framework
function, like graphic rendering, data storage, web browsing, and the
Android runtime - the core java libraries for running Android
application.
- Linux kernel - Communication layer for the underlying hardware.
7. 1.4. Application Components
- Application components:
- are the essential building blocks of an Android Application.
- uses <application> … </application> in AndroidManifest.xml to describes
each component of the application and how they interact.
- There are 4 Components of Application:
- Activity
- Service
- Broadcast receivers (receiver)
8. 1.4. Android Component - Activity
- An activity is the visual representation of an Android application.
- An Android application can have several activities.
- Activities use views and fragments to create their user interface and to interact
with the user.public class MainActivity extends Activity {
}
or
public class MainActivity extends AppCompatActivity{
}
9.
10. 1.4. Application Component - Service
- A service performs tasks without
providing an user interface.
- It can communicate with other
Android components and send
notifications to the user. For
example, a broadcast receiver can
notify the user via the notification
framework in Android.
11. 1.4. Application Component - Broadcast Receiver
- A receiver can be registered to
listen to system messages and
intents. A receiver gets notified by
the Android system if the specified
event occurs.
- For example, Battery is getting low.
12. 1.4. Application Component - Content Provider
- A provider defines a structured interface to application data. A provider can
be used for accessing data within one application, but can also be used to
share data with other applications.
- Android contains an SQLite database which is frequently used in conjunction
with a content provider. The SQLite database would store the data, which
would be accessed via the provider.
13.
14.
15. 1.5. Android Developer Tools
- The Android development tooling:
- converts these files(Java and Resource) into an Android application
- compile, package, deploy and start application which are developed
- necessary tools need - the Android Software Development Kit (Android
SDK) and the Gradle tooling
- The Android SDK: contains the Android debug bridge (adb) - allows
managing the device (virtual or real Android device) or debugging your
application.
16. 1.6 System requirements
- Microsoft Windows 7/8/10 (32-bit or 64-bit)
- 2 GB RAM minimum, 8 GB RAM recommended
- 2 GB of available disk space minimum, 4 GB Recommended (500 MB for IDE +
1.5 GB for Android SDK and emulator system image)
- 1280 x 800 minimum screen resolution
- JDK 8
- For accelerated emulator: 64-bit operating system and Intel processor with
support for Intel VT-x, Intel EM64T (Intel 64), and Execute Disable (XD) Bit
functionality
17. 1.7. Download and Installation
- Install JDK + Set path environment to JAVA_HOME
- Download Android Studio : http://developer.android.com/sdk/index.html
- Installation Android Studio follow the wizard
18. 1.8 Managing the Android API Level
- The Android SDK manager allows you to install and delete specific Android OS
version.
- Select Tools -> Android -> SDK Manager or the SDK Manager icon in the
toolbar -> It will show the api install or delete or update
20. 5.1 Resource files
- Resource files must be placed in the /res directory of your application in a
predefined sub-folder.
- You can also append additional qualifiers to the folder name - resource
qualifiers .
- These qualifiers indicate that the related resources should be used for special
device configurations. For example, you can specify that a layout file is only
valid for a certain screen size.