A Seminar Report on
“Android”
At
“Bhagwan Mahavir College of Computer Application”,
Bharthana-Vesu, Surat
As A Partial Fulfilment for The Degree Of
Bachelor of Computer Application
2024-2025
Guided By: Submitted By:
Asst. Prof. Ravi Patel Mr. Bhavya Bhalala
Bhagwan Mahavir College of Computer Application
Bharthana-Vesu, Surat
Affiliated With
Bhagwan Mahavir University, Surat, Gujarat, India
BHAGWAN MAHAVIR COLLEGE OF COMPUTER APPLICATION
Constituent College of Bhagwan Mahavir University
[email protected] 0261-6770125/23, +91-7575803091
www.bmusurat.ac.in VIP Road, Surat, Gujarat–395007
This is to certify that the Seminar entitled “Smart City ” has been
submitted by BHALALA BHAVYA ANILBHAI Exam
No. 2202020101049 at Bhagwan Mahavir College of Computer
Application as a partial fulfilment of the requirement for the degree of
Bachelor of Computer Application for the academic Year 2024-25.
Place: Surat
Date:
Asst. Prof. Ravi Patel Dr. Hetal Modi
(Project Guide, BMCCA) (Program Head)
Preface
Android has revolutionized the mobile industry, transforming the way we interact with
technology in our daily lives. This presentation delves into the evolution, architecture, and
significance of Android, providing a comprehensive understanding of its core components
and development framework. By exploring its history, system structure, and development
environment, we aim to highlight Android’s dominance and its future potential in the ever-
evolving tech landscape.
This project would not have been possible without the support and guidance of several
individuals. We express our sincere gratitude to Asst. Prof. Ravi Patel, our project guide at
BMCCA, for his invaluable mentorship and insights throughout our research. We also extend
our heartfelt appreciation to Dr. Hetal Modi, our esteemed Program Head, for her
encouragement and continuous support.
Additionally, we would like to thank our peers for their collaboration, discussions, and
assistance during this journey. Our appreciation also goes out to all faculty members who
provided guidance and knowledge, helping us refine our understanding of Android and its
vast ecosystem.
With this presentation, we strive to deliver a clear and informative overview of Android,
hoping to contribute to a deeper understanding of its impact on the tech world.
2202020101049-BECHLOR OF COMPUTER APPLICATION 3|PAGE
TABLE OF CONTANT
Contents
PREFACE ................................................................................................................................. 3
WHAT IS ANDROID? ............................................................................................................ 6
WHY ANDROID DOMINATES THE MARKET? ......................................................... 6
KEY FEATURES AND ADVANTAGES .......................................................................... 7
ANDROID VS. OTHER OPERATING SYSTEMS ......................................................... 7
VERDICT: ........................................................................................................................ 7
HISTORY OF ANDROID ...................................................................................................... 9
THE BIRTH OF ANDROID: FOUNDING & EARLY DEVELOPMENT ............... 9
ACQUISITION BY GOOGLE & INITIAL GROWTH .............................................. 9
EVOLUTION OF ANDROID VERSIONS (CUPCAKE TO CURRENT) ................ 9
MILESTONES & MAJOR UPDATES OVER THE YEARS ................................... 10
ANDROID ARCHITECTURE ............................................................................................. 12
(A) LINUX KERNEL LAYER ..................................................................................... 12
(B) HARDWARE ABSTRACTION LAYER (HAL) ................................................. 12
(C) NATIVE LIBRARIES & ANDROID RUNTIME (ART).................................... 13
(D) APPLICATION FRAMEWORK .......................................................................... 13
(E) APPLICATION LAYER ........................................................................................ 13
SUMMARY OF ANDROID ARCHITECTURE ........................................................ 14
ANDROID DEVELOPMENT ENVIRONMENT .............................................................. 16
(A) SETTING UP ANDROID DEVELOPMENT (SDK, NDK, IDES) .................... 16
(B) ANDROID STUDIO & ESSENTIAL TOOLS ..................................................... 17
(C) DEBUGGING & TESTING IN ANDROID ......................................................... 17
SUMMARY .................................................................................................................... 18
ANDROID APP COMPONENTS & LIFECYCLE ........................................................... 19
(A) ACTIVITIES, FRAGMENTS, AND INTENTS................................................... 19
(B) SERVICES, BROADCAST RECEIVERS, AND CONTENT PROVIDERS .... 19
(C) APP LIFECYCLE MANAGEMENT & BEST PRACTICES ............................ 20
SUMMARY OF ANDROID APP COMPONENTS & LIFECYCLE ...................... 21
ANDROID SECURITY & PERMISSIONS ........................................................................ 22
(A) PERMISSION MODEL & USER CONTROLS .................................................. 22
2202020101049-BECHLOR OF COMPUTER APPLICATION 4|PAGE
(B) ANDROID SECURITY FEATURES (SANDBOXING, ENCRYPTION, PLAY
PROTECT) ..................................................................................................................... 22
(C) COMMON SECURITY VULNERABILITIES & FIXES .................................. 23
SUMMARY OF ANDROID SECURITY & PERMISSIONS ................................... 24
ANDROID PERFORMANCE OPTIMIZATION .............................................................. 25
(A) MEMORY MANAGEMENT & GARBAGE COLLECTION ........................... 25
(B) BATTERY OPTIMIZATION & DOZE MODE .................................................. 25
(C) BEST PRACTICES FOR EFFICIENT CODE .................................................... 26
FUTURE OF ANDROID ...................................................................................................... 27
(A) UPCOMING FEATURES & TRENDS ................................................................ 27
(B) ANDROID’S ROLE IN IOT, AI, AND BEYOND ............................................... 27
(C) CHALLENGES & POSSIBLE DEVELOPMENTS ............................................ 27
CONCLUSION .............................................................................................................. 28
2202020101049-BECHLOR OF COMPUTER APPLICATION 5|PAGE
What is Android?
Android is an open-source mobile operating system developed by Google, designed
primarily for touchscreen devices like smartphones and tablets. Built on a customized Linux
kernel, it provides a flexible and scalable platform for app development, supporting a vast
ecosystem of developers and manufacturers. Since its initial release in 2008, Android has
grown into the most widely used mobile OS in the world, powering billions of devices
across various form factors, including smartphones, tablets, TVs, smartwatches, and even
automotive systems.
Why Android Dominates the Market?
Android’s dominance isn’t accidental—it’s a result of several strategic advantages:
• Open-Source & Free – Unlike iOS, which is tightly controlled by Apple, Android is
open-source, allowing manufacturers to modify and customize it for their devices.
• Massive Manufacturer Adoption – Companies like Samsung, Xiaomi, OnePlus,
Oppo, Vivo, and Google itself use Android, making it the go-to OS worldwide.
• Wide Device Variety & Price Range – Android runs on everything from budget
phones to flagship powerhouses, catering to every income level.
• Customizability – Users can tweak almost every aspect of Android, from home
screens to system-wide themes, something iOS users can only dream about.
• Huge App Ecosystem – The Google Play Store offers millions of apps, far more
than any other app store.
• Rapid Innovation & Frequent Updates – Google continuously updates Android
with new features, performance improvements, and security patches.
2202020101049-BECHLOR OF COMPUTER APPLICATION 6|PAGE
Key Features and Advantages
Android isn’t just popular—it’s packed with features that make it the most powerful
mobile OS:
Multitasking & Multi-window Support – Unlike iOS, Android has long supported true
multitasking.
Custom Home Screens & Widgets – Personalization is a core strength, allowing users
to create a unique experience.
Google Assistant & AI Integration – Voice commands, predictive typing, and smart
automation make tasks easier.
Support for Multiple Hardware Platforms – Android runs on a variety of processors
(ARM, x86, etc.), giving manufacturers flexibility.
Seamless Cloud Integration – Google Drive, Photos, and other cloud services are
deeply embedded.
Diverse App Distribution Methods – Apps can be installed via the Play Store, third-
party stores, or sideloaded as APKs.
Security Features – Regular updates, Play Protect, and encrypted storage keep devices
safer.
Android vs. Other Operating Systems
A quick comparison of Android against its biggest competitors:
Feature Android iOS (Apple) Windows HarmonyOS
(RIP) (Huawei)
Customization Extreme Limited Basic Moderate
Device Huge Only Dead Growing
Variety iPhones
App Store Google Play Apple App Limited Limited
+ 3rd Party Store Only
Market Share 70%+ ~28% 0% Niche
(Dead)
Open Source Yes No No Partially
AI Integration Google Siri Cortana Xiaoyi
Assistant (RIP)
Security Strong Very Strong Weak Growing
Verdict:
• If you want customization, variety, and affordability → Go Android.
• If you love Apple’s ecosystem, walled garden, and restrictions → Go iOS.
• If you like nostalgia for failed operating systems → Go Windows (oh wait, you
can't).
• If you're in China and banned from using Google services → HarmonyOS is
your only choice.
2202020101049-BECHLOR OF COMPUTER APPLICATION 7|PAGE
Android remains the most dominant, flexible, and widely used OS, making it the
undisputed king of mobile platforms.
2202020101049-BECHLOR OF COMPUTER APPLICATION 8|PAGE
HISTORY OF ANDROID
THE BIRTH OF ANDROID: FOUNDING & EARLY DEVELOPMENT
Android was founded in 2003 by Andy Rubin, Rich Miner, Nick Sears, and Chris White
in Palo Alto, California. Initially, the company aimed to develop an advanced operating
system for digital cameras, but they soon realized the potential of mobile phones and
shifted their focus. The goal was to create a powerful, open-source mobile OS that could
compete with the likes of Symbian and Windows Mobile.
However, Android faced financial difficulties early on. To keep the company afloat, Andy
Rubin had to borrow money from friends and pitch to investors who were skeptical of his
vision. But the persistence paid off, and the company continued development until it caught
the attention of Google.
ACQUISITION BY GOOGLE & INITIAL GROWTH
In 2005, Google saw the potential of Android and acquired the company for $50 million.
Andy Rubin and his team joined Google, where they secretly worked on a Linux-based
mobile operating system. The vision was to create an open-source platform that would
allow hardware manufacturers to build their own devices without relying on proprietary
software like Nokia's Symbian or Microsoft’s Windows Mobile.
In 2007, Google officially unveiled Android as part of the Open Handset Alliance (OHA),
a consortium of technology companies committed to building open standards for mobile
devices. This was a game-changer, as it allowed different manufacturers to use Android on
their devices without heavy licensing fees.
The first commercially available Android smartphone, the HTC Dream (T-Mobile G1), was
released in 2008. It featured a touchscreen, a slide-out physical keyboard, and the very first
version of Android (1.0), setting the stage for Android’s dominance.
EVOLUTION OF ANDROID VERSIONS (CUPCAKE TO CURRENT)
Android has gone through numerous updates, each improving performance, security, and
usability. The versions were initially named after desserts in alphabetical order:
1. Android 1.0 & 1.1 (2008-2009) – Basic features like a web browser, camera support,
and Google apps.
2. Android 1.5 Cupcake (2009) – Introduced the on-screen keyboard, widgets, and
video recording.
3. Android 1.6 Donut (2009) – Brought CDMA support, paving the way for more
carriers.
4. Android 2.0–2.1 Eclair (2009) – Introduced Google Maps Navigation and live
wallpapers.
5. Android 2.2 Froyo (2010) – Added Flash support and hotspot functionality.
6. Android 2.3 Gingerbread (2010) – Introduced better UI, NFC support, and
improved gaming performance.
2202020101049-BECHLOR OF COMPUTER APPLICATION 9|PAGE
7. Android 3.0 Honeycomb (2011) – Tablet-exclusive version with a redesigned UI.
8. Android 4.0 Ice Cream Sandwich (2011) – Unified phone and tablet UI, introduced
Face Unlock.
9. Android 4.1–4.3 Jelly Bean (2012-2013) – Project Butter made animations
smoother, Google Now was introduced.
10. Android 4.4 KitKat (2013) – Better RAM management, "OK Google" voice
command.
11. Android 5.0–5.1 Lollipop (2014-2015) – Material Design, new notification system.
12. Android 6.0 Marshmallow (2015) – Doze mode for battery life, app permissions
overhaul.
13. Android 7.0–7.1 Nougat (2016) – Multi-window support, VR enhancements.
14. Android 8.0–8.1 Oreo (2017-2018) – Picture-in-Picture mode, improved boot
speed.
15. Android 9 Pie (2018) – Introduced gesture navigation and adaptive battery.
16. Android 10 (2019) – Dark mode, improved security and privacy settings.
17. Android 11 (2020) – Chat bubbles, better media controls.
18. Android 12 (2021) – Material You, major UI revamp.
19. Android 13 (2022) – Improved privacy, per-app language settings.
20. Android 14 (2023) – AI-powered features, satellite connectivity support.
Google stopped using dessert names publicly after Android 9, but internally they still exist.
MILESTONES & MAJOR UPDATES OVER THE YEARS
• 2008: Launch of Android 1.0 with the HTC Dream.
• 2010: Android becomes the world’s most-used mobile OS, surpassing Symbian.
• 2011: Google acquires Motorola Mobility to strengthen Android hardware.
• 2014: Android Wear introduced for smartwatches.
• 2016: Google launches Pixel smartphones, showing off pure Android.
• 2017: Project Treble introduced to speed up Android updates.
• 2019: Huawei banned from using Google services, leading to HarmonyOS.
• 2021: Material You UI introduced for deep customization.
• 2023 & Beyond: AI-powered features, foldable phone support, satellite connectivity
improvements.
Android’s journey has been nothing short of revolutionary, evolving from a small startup idea
to the backbone of billions of devices worldwide.
2202020101049-BECHLOR OF COMPUTER APPLICATION 10 | P A G E
2202020101049-BECHLOR OF COMPUTER APPLICATION 11 | P A G E
ANDROID ARCHITECTURE
Android’s architecture is structured into five key layers, each playing a crucial role in the
operating system’s functionality. These layers ensure efficient communication between
hardware and applications, providing a seamless user experience.
(A) LINUX KERNEL LAYER
The foundation of Android is the Linux Kernel, which acts as the core of the OS, managing
hardware interactions, security, and core system functions.
CORE SYSTEM SERVICES
• Process Management – Allocates system resources and manages running processes.
• Memory Management – Handles RAM allocation to optimize performance.
• Power Management – Controls battery usage and device sleep states.
• Device Drivers – Enables communication between hardware components like
cameras, audio, and networking.
SECURITY & HARDWARE ABSTRACTION
• Security Modules – Implements encryption, secure boot, and app sandboxing.
• Hardware Abstraction – Provides a standardized interface for hardware
components, allowing Android to run on various devices.
(B) HARDWARE ABSTRACTION LAYER (HAL)
The Hardware Abstraction Layer (HAL) acts as a bridge between the Linux Kernel and
higher-level Android software. It allows Android to communicate with hardware without
needing to modify the OS for different devices.
ROLE OF HAL IN HARDWARE COMMUNICATION
• HAL ensures that Android can work with different chipsets, cameras, sensors, and
modems without major changes to the OS.
• It provides standardized APIs for hardware manufacturers to integrate their
components into Android devices.
HAL AND VENDOR-SPECIFIC IMPLEMENTATIONS
• Device manufacturers (OEMs) can customize HAL to optimize performance for
their specific hardware.
• Android’s Project Treble introduced a modular HAL structure, separating vendor
updates from system updates, making OS upgrades easier.
2202020101049-BECHLOR OF COMPUTER APPLICATION 12 | P A G E
(C) NATIVE LIBRARIES & ANDROID RUNTIME (ART)
This layer includes core libraries and the Android Runtime (ART), responsible for
executing applications efficiently.
CORE LIBRARIES
These libraries provide essential functionalities used by apps and system services:
• SQLite – Manages local database storage.
• OpenGL ES – Handles graphics rendering for games and UI animations.
• WebKit – Supports web browsing and embedded web views.
• SSL/TLS – Ensures secure communication over networks.
ANDROID RUNTIME (ART) & ITS ROLE IN EXECUTION
• ART (Android Runtime) replaced the old Dalvik Virtual Machine, improving
performance, battery life, and app startup times.
• Uses Ahead-of-Time (AOT) compilation, meaning apps are compiled once during
installation rather than every time they run, making execution faster.
(D) APPLICATION FRAMEWORK
This layer provides essential services and APIs that developers use to create Android
applications.
KEY FRAMEWORK COMPONENTS
• Activity Manager – Handles app lifecycle and navigation between screens.
• Content Providers – Manages access to shared data like contacts and files.
• Notification Manager – Manages system-wide notifications.
• Location Manager – Provides GPS and network-based location tracking.
• Resource Manager – Handles UI components, themes, and localization.
APIS FOR DEVELOPERS
• Developers use Java/Kotlin APIs to interact with system services.
• The Jetpack Libraries enhance app development with modern architecture patterns.
(E) APPLICATION LAYER
This is the topmost layer, consisting of all the user-installed apps and pre-installed system
applications.
2202020101049-BECHLOR OF COMPUTER APPLICATION 13 | P A G E
PRE-INSTALLED APPS & USER APPLICATIONS
• System Apps – Pre-installed by manufacturers (e.g., Phone, Messages, Settings,
Camera).
• User Apps – Downloaded and installed from the Play Store or third-party sources.
ROLE OF PLAY STORE AND APKS
• The Google Play Store serves as the primary platform for app distribution and
updates.
• Apps are packaged as APK (Android Package) files, which contain all necessary
resources and code.
• Since Android supports third-party app stores and sideloading, users can install
apps outside the Play Store, increasing flexibility.
SUMMARY OF ANDROID ARCHITECTURE
Layer Description Key components
Linux kernel Core system operations Device drivers, memory &
power management
Hal (hardware Bridge between hardware Vendor-specific
abstraction layer) and software implementations, hardware
apis
Native libraries & Optimized execution and Sqlite, opengl, webkit, art
android runtime (art) essential services
Application framework Developer tools and Activity manager, content
system services providers, apis
Application layer End-user apps and pre- Play store, apks, system & user
installed system apps applications
This structured approach ensures Android remains powerful, flexible, and scalable,
making it the dominant mobile operating system worldwide.
2202020101049-BECHLOR OF COMPUTER APPLICATION 14 | P A G E
2202020101049-BECHLOR OF COMPUTER APPLICATION 15 | P A G E
ANDROID DEVELOPMENT ENVIRONMENT
Developing Android applications requires setting up the right tools and understanding the
development environment. This includes installing the Android SDK (Software
Development Kit), using an IDE like Android Studio, and utilizing debugging and testing
tools.
(A) SETTING UP ANDROID DEVELOPMENT (SDK, NDK, IDES)
ANDROID SDK (SOFTWARE DEVELOPMENT KIT)
The Android SDK is a collection of tools, libraries, and APIs required to build Android apps.
It includes:
• Android Compiler – Converts source code into executable APK files.
• Build Tools – Includes tools for compiling, packaging, and debugging applications.
• Android Emulator – A virtual Android device for testing apps without physical
hardware.
• Platform APIs – Provides access to Android system functions (camera, GPS, etc.).
ANDROID NDK (NATIVE DEVELOPMENT KIT)
• The NDK is used for developing Android apps in C or C++, rather than Java/Kotlin.
• It is useful for performance-critical applications, such as games and high-speed
processing tasks.
IDES (INTEGRATED DEVELOPMENT ENVIRONMENTS)
The primary IDEs for Android development are:
1. Android Studio – The official IDE by Google, offering complete tools for app
development.
2. Visual Studio Code (VS Code) – Lightweight alternative, often used with React
Native or Flutter.
3. Eclipse (Legacy) – Previously used before Android Studio was released, now largely
outdated.
2202020101049-BECHLOR OF COMPUTER APPLICATION 16 | P A G E
(B) ANDROID STUDIO & ESSENTIAL TOOLS
ANDROID STUDIO – THE PRIMARY DEVELOPMENT ENVIRONMENT
Android Studio is the most widely used IDE for Android development, offering:
Code Editor with IntelliSense – Smart suggestions and error detection.
Gradle Build System – Automates the building process.
Emulator Support – Allows testing without a real device.
Layout Editor – Drag-and-drop interface design.
Profiling Tools – Helps optimize CPU, memory, and network usage.
ESSENTIAL TOOLS FOR ANDROID DEVELOPMENT
• Gradle – Automates builds and manages dependencies.
• ADB (Android Debug Bridge) – Allows communication with devices for testing and
debugging.
• Logcat – Real-time log viewer for app debugging.
• ProGuard & R8 – Tools for code shrinking and obfuscation, improving app security.
• Firebase Tools – For integrating cloud messaging, authentication, and analytics.
(C) DEBUGGING & TESTING IN ANDROID
DEBUGGING IN ANDROID
1. Logcat – Displays logs from an app, useful for identifying issues.
2. Breakpoints & Debugger – Pauses code execution to analyze behavior.
3. Android Profiler – Monitors CPU, memory, and network usage.
4. Emulator & Physical Device Debugging – Allows running and testing apps directly.
TESTING IN ANDROID
Testing is crucial to ensure that apps function correctly across various devices and versions.
✔ Unit Testing – Tests individual components (e.g., JUnit, Mockito).
✔ UI Testing – Tests user interface behavior (e.g., Espresso, UI Automator).
✔ Automated Testing – Runs pre-defined test cases on multiple devices (Firebase Test Lab).
✔ Beta Testing & Deployment – Uses Google Play Console or third-party platforms to test
apps before public release.
2202020101049-BECHLOR OF COMPUTER APPLICATION 17 | P A G E
SUMMARY
Component Description
Sdk & ndk Provides essential tools and libraries for app development.
Android studio The primary ide for developing and debugging android apps.
Gradle Automates the build process and dependency management.
Adb & logcat Used for debugging and real-time logging.
Testing frameworks Includes unit testing, ui testing, and automated testing.
A proper development environment ensures smooth and efficient Android app creation,
making it easier to build, test, and optimize applications.
2202020101049-BECHLOR OF COMPUTER APPLICATION 18 | P A G E
ANDROID APP COMPONENTS & LIFECYCLE
Android apps are built using four main components that work together to provide a
seamless user experience. Each component has a specific role in handling user interactions,
background tasks, and system communication. Managing their lifecycles efficiently is crucial
to ensure smooth performance, battery efficiency, and responsiveness.
(A) ACTIVITIES, FRAGMENTS, AND INTENTS
ACTIVITIES
• An Activity represents a single screen in an Android app.
• It manages user interaction and UI elements (buttons, text fields, images, etc.).
• Example: A login screen and a dashboard screen are two separate activities.
✔ Lifecycle of an Activity:
1. onCreate() – Called when the activity is first created.
2. onStart() – When the activity becomes visible.
3. onResume() – When the user interacts with the activity.
4. onPause() – When the activity is partially obscured.
5. onStop() – When the activity is no longer visible.
6. onDestroy() – When the activity is removed from memory.
FRAGMENTS
• Fragments are reusable UI components inside an activity.
• They allow better UI management for different screen sizes (mobile/tablet).
• Example: A news app might have a list fragment (left) and a details fragment (right).
INTENTS
• Intents allow communication between different components (activities, services,
broadcast receivers).
• Explicit Intent – Directly targets a specific component.
o Example: Open another activity within the same app.
• Implicit Intent – Lets the system decide the best component to handle it.
o Example: Opening a URL using any available browser app.
(B) SERVICES, BROADCAST RECEIVERS, AND CONTENT PROVIDERS
SERVICES
• Services run in the background to perform long-running operations without UI.
• Example: Playing music in the background while using other apps.
• Types of Services:
o Foreground Service – Runs with a visible notification (e.g., media player).
o Background Service – Runs without user interaction (e.g., syncing data).
2202020101049-BECHLOR OF COMPUTER APPLICATION 19 | P A G E
o Bound Service – Provides an interface for communication between
components (e.g., location tracking).
BROADCAST RECEIVERS
• Listens for system-wide or app-specific broadcast messages.
• Example:
o Detects when the battery is low.
o Detects when the device has finished booting.
• Types of Broadcasts:
o Ordered Broadcasts – Delivered in sequence to receivers with priority.
o Sticky Broadcasts – Stores the broadcast message for other apps to read later
(deprecated).
CONTENT PROVIDERS
• Manages shared app data (contacts, media files, etc.).
• Allows different apps to access structured data using a URI (Uniform Resource
Identifier).
• Example: The Contacts app acts as a content provider, allowing other apps to fetch
contact details.
(C) APP LIFECYCLE MANAGEMENT & BEST PRACTICES
Efficient lifecycle management prevents memory leaks, performance issues, and battery
drain.
2202020101049-BECHLOR OF COMPUTER APPLICATION 20 | P A G E
BEST PRACTICES:
✔ Use ViewModels – Stores UI-related data to survive configuration changes (e.g., screen
rotation).
✔ Handle Activity & Fragment Lifecycle Properly – Release resources in onPause() and
onDestroy().
✔ Use WorkManager for Background Tasks – Ensures efficient background execution
without draining battery.
✔ Optimize for Low Memory Conditions – Avoid unnecessary background processes and
cache data effectively.
✔ Register and Unregister Broadcast Receivers – Prevents memory leaks by unregistering
them when not needed.
SUMMARY OF ANDROID APP COMPONENTS & LIFECYCLE
Component Description Example
Activity Represents a ui screen Login screen, dashboard
Fragment A reusable ui component within News list & detail pane
an activity
Intent Enables communication between Opening a url in a browser
components
Service Runs background tasks without Music player running in the
ui background
Broadcast Listens for system-wide Detecting airplane mode
receiver messages activation
Content Shares app data with other apps Contacts app providing access to
provider phone numbers
Properly managing these components ensures a smooth user experience, efficient resource
usage, and better app performance.
2202020101049-BECHLOR OF COMPUTER APPLICATION 21 | P A G E
ANDROID SECURITY & PERMISSIONS
Android security is a multi-layered system designed to protect user data, device integrity,
and app functionality. It includes strict permission controls, sandboxing, encryption, and
continuous threat detection mechanisms like Google Play Protect. However, security
vulnerabilities still exist, making it crucial to implement best practices for safeguarding apps
and user data.
(A) PERMISSION MODEL & USER CONTROLS
Android uses a runtime permission model to give users control over what data and features
an app can access.
TYPES OF ANDROID PERMISSIONS:
1. Normal Permissions – Automatically granted (low-risk).
o Example: Internet access, setting alarms.
2. Dangerous Permissions – Require explicit user approval at runtime.
o Example: Location, camera, microphone.
3. Signature Permissions – Only granted if the requesting app is signed with the same
key as the provider app.
o Example: Internal app communication within the same developer ecosystem.
RUNTIME PERMISSION REQUEST FLOW:
1. App requests permission when needed.
2. User grants or denies access.
3. App handles permission result (granted or denied).
4. If denied, the app can re-request (but not force grant).
✔ Best Practices for Handling Permissions:
• Request only necessary permissions.
• Explain why the permission is needed (before requesting).
• Handle denial gracefully without crashing the app.
• Follow the "Least Privilege Principle" – don’t request permissions you don’t
absolutely need.
(B) ANDROID SECURITY FEATURES (SANDBOXING, ENCRYPTION, PLAY
PROTECT)
1. SANDBOXING
• Every Android app runs in its own isolated environment (sandbox).
• This prevents one app from accessing another app’s data.
• Even if malware infects one app, it cannot spread to others.
2202020101049-BECHLOR OF COMPUTER APPLICATION 22 | P A G E
2. DATA ENCRYPTION
• File-Based Encryption (FBE) – Encrypts data at the file level for better security.
• Full-Disk Encryption (FDE) [Older Versions] – Encrypts entire storage but with
lower flexibility.
• Keystore API – Securely stores cryptographic keys on the device.
3. GOOGLE PLAY PROTECT
• Automatically scans apps in the Play Store for malware.
• Warns users about suspicious apps before installation.
• Removes malicious apps remotely if they are later flagged as harmful.
✔ Best Practices for Secure App Development:
• Use HTTPS (TLS 1.2+) for network communication.
• Secure sensitive data using AES encryption.
• Never store plaintext passwords or API keys in code.
• Use Biometric Authentication APIs instead of storing user credentials.
(C) COMMON SECURITY VULNERABILITIES & FIXES
Even with built-in security, Android apps can be vulnerable to:
1. INSECURE DATA STORAGE
Problem: Storing sensitive data (e.g., passwords, tokens) in SharedPreferences or SQLite
databases without encryption.
✔ Fix: Always encrypt sensitive data using the Android Keystore API or AES encryption.
2. INSECURE NETWORK COMMUNICATION
Problem: Sending data over HTTP instead of HTTPS, allowing Man-in-the-Middle
(MITM) attacks.
✔ Fix: Use TLS 1.2+ and SSL pinning to prevent interception.
3. IMPROPER PERMISSIONS HANDLING
Problem: Requesting unnecessary permissions increases the attack surface.
✔ Fix: Follow the least privilege principle and only request permissions when absolutely
needed.
4. CODE INJECTION (SQL INJECTION, XSS)
Problem: Not sanitizing user input can lead to SQL injection and cross-site scripting
(XSS) attacks.
✔ Fix: Use parameterized queries with SQLite and validate all user input.
2202020101049-BECHLOR OF COMPUTER APPLICATION 23 | P A G E
5. REVERSE ENGINEERING & CODE TAMPERING
Problem: Attackers decompile APKs to extract sensitive data or modify app behavior.
✔ Fix: Use ProGuard or R8 to obfuscate code and Google Play Integrity API to detect
tampering.
SUMMARY OF ANDROID SECURITY & PERMISSIONS
Security feature Description Best practice
Permission model Restricts app access to sensitive Request only required
data permissions
Sandboxing Isolates apps to prevent cross- Use storage correctly & limit
access file sharing
Encryption Protects stored data and network Use keystore api & tls 1.2+
communication
Google play Scans & removes malicious apps Keep apps updated & avoid
protect third-party apks
Secure coding Prevents data leaks & exploits Sanitize inputs, use https, and
practices encrypt data
By implementing robust security measures, Android apps can protect user data, prevent
unauthorized access, and resist cyber threats.
2202020101049-BECHLOR OF COMPUTER APPLICATION 24 | P A G E
ANDROID PERFORMANCE OPTIMIZATION
Optimizing Android performance is crucial for smooth user experience, battery efficiency,
and overall app stability. Poorly optimized apps lead to lag, crashes, excessive battery
drain, and memory leaks—basically, the kind of garbage no user wants.
(A) MEMORY MANAGEMENT & GARBAGE COLLECTION
HOW ANDROID HANDLES MEMORY
Android uses automatic memory management with Garbage Collection (GC) to free up
unused memory. However, bad coding practices can cause memory leaks, unnecessary
object creation, and lag spikes.
GARBAGE COLLECTION (GC) MECHANISM
• Dalvik GC (Old Android Runtime) – Slower, led to frequent UI stutters.
• ART (Android Runtime) GC – More efficient, optimized for better performance.
✔ Best Practices for Memory Optimization:
• Use WeakReferences for large objects to avoid memory leaks.
• Avoid holding references to Context unnecessarily (especially in static fields).
• Use RecyclerView instead of ListView for better memory efficiency.
• Minimize bitmap usage and use Glide/Picasso for efficient image loading.
• Release unused resources in onDestroy() and onPause().
(B) BATTERY OPTIMIZATION & DOZE MODE
Android prioritizes battery life by managing background tasks and resource usage.
KEY BATTERY OPTIMIZATION FEATURES:
1. Doze Mode – Kicks in when the device is idle, limiting background processes.
2. App Standby – Restricts rarely used apps to conserve battery.
3. Background Execution Limits – Reduces CPU & network usage for background
apps.
✔ Best Practices for Battery Optimization:
• Use JobScheduler or WorkManager for background tasks instead of background
services.
• Minimize wake locks and use AlarmManager wisely.
• Optimize network calls by batching API requests.
• Prefer Firebase Cloud Messaging (FCM) over polling for push notifications.
2202020101049-BECHLOR OF COMPUTER APPLICATION 25 | P A G E
(C) BEST PRACTICES FOR EFFICIENT CODE
✔ Reduce Main Thread Work – Keep expensive operations off the UI thread (use
coroutines or RxJava).
✔ Optimize Database Queries – Use indexes and avoid unnecessary reads/writes.
✔ Use Lazy Loading – Load data only when needed (e.g., pagination for lists).
✔ Profile & Debug Performance – Use Android Profiler to analyze CPU, memory, and
battery usage.
2202020101049-BECHLOR OF COMPUTER APPLICATION 26 | P A G E
FUTURE OF ANDROID
Android is constantly evolving, integrating AI, IoT, and cutting-edge hardware
advancements. The future promises more seamless, intelligent, and secure experiences.
(A) UPCOMING FEATURES & TRENDS
Android’s Future Innovations:
✔ Android AI Integration – Smarter Google Assistant, AI-powered personalization.
✔ Foldable & Wearable Optimizations – Better support for foldable phones &
smartwatches.
✔ Enhanced Privacy Features – Stricter app tracking controls & permission management.
✔ Faster & More Efficient ART – Reduced app startup time & memory footprint.
(B) ANDROID’S ROLE IN IOT, AI, AND BEYOND
Internet of Things (IoT):
• Android Things & Google Home expanding smart home ecosystems.
• Integration with smart appliances, cars, and industrial devices.
Artificial Intelligence (AI):
• Google Bard & AI-powered chatbots embedded into Android devices.
• Machine Learning APIs making apps more adaptive & personalized.
5G & Edge Computing:
• Ultra-fast real-time processing for gaming, streaming, and cloud applications.
• Lower latency, enhancing mobile AR/VR experiences.
(C) CHALLENGES & POSSIBLE DEVELOPMENTS
Security & Privacy Concerns – Stricter data regulations, improving biometric
authentication.
Fragmentation Issues – Too many devices, slow Android updates across brands.
Battery & Performance Bottlenecks – Further improvements in low-power AI
processing.
Cross-Platform Development – Increasing adoption of Flutter, Jetpack Compose, and
Kotlin Multiplatform.
2202020101049-BECHLOR OF COMPUTER APPLICATION 27 | P A G E
CONCLUSION
Android’s future is all about AI, security, efficiency, and cross-platform expansion. With
continuous innovations, it will dominate smartphones, smart homes, wearables, and
beyond.
Developers must stay ahead by learning new tools, following best practices, and
optimizing their apps for future advancements.
2202020101049-BECHLOR OF COMPUTER APPLICATION 28 | P A G E