02 Introduction to Android Application.pptx

Full Transcript

Introduction to Applications Development and Android Studio What is Android? An open source and Linux-based Operating System for mobile devices such as smartphones and tablet computers. Developed by the Open Handset Alliance, led by Google, and other companies. It offers a unified app...

Introduction to Applications Development and Android Studio What is Android? An open source and Linux-based Operating System for mobile devices such as smartphones and tablet computers. Developed by the Open Handset Alliance, led by Google, and other companies. It offers a unified approach to application development for mobile devices which means developers need to develop only for Android, and their applications should be able to run on different devices powered by Android. ANDROID Overview 200 Google acquired Android Inc. 5 200 the first commercial version, Android 1.0, was released 8 2009 2010 Cupcake (Android 1.5) to Froyo (Android 2.2) 2010 Gingerbread (Android 2.3) to Honeycomb (3.0) from 2011 tablet computer 2011 2019 Ice Cream Sandwich (Android 4.0) to Pie (Android 9.0) 2019 2023 Android 10 to Android 14 ANDROID Evolution Android API Relea Features Version Lev se el Cupcake 3 2009 Support widgets, search, browsers navigation apps Donut 4 2009 Screen capture, voice command Eclair 5 2010 Battery saver, enable in low resolution (320x240), keyboard auto-correct Froyo 8 2010 High security, cloud API, gesture detection Gingerbread 9 2011 NFC range in 10cm, audio video calls, 3G supported, gyroscope sensor Honeycomb 11 2011 Symmetric multiprocessor, multitasking, google talk, 3D effects Ice Cream 14 2011 Notification pop-up on lock screen, fast image capture Sandwich Jellybean 16 2012 Speed, audio & video calling, remote access Kit-kat 19 2013 Responsive, tri core CPU, cloud response ANDROID Evolution Android API Relea Features Version Lev se el Nougat 25 2016 Multi-window support, improved notification, Google Assistant Oreo 26 2017 Multi-tasking with video, auto fill support, background app restriction Pie 28 2018 Gesture navigation, adaptive battery, digital wellbeing, limit app usage 10 29 2019 System-wide dark theme, full gesture navigation, privacy control, support foldable devices, enhanced 5G experience 11 30 2020 Dedicated space in notification, chat bubbles, smart device control 12 31 2021 Material you, approximately location, mic/camera indicators 13 33 2022 Per-App Language, Bluetooth LE, spatial audio, privacy and security enhanced 14 34 2023 Enhanced lock screen, improved battery life, health connect, Features of ANDROID Feature Description Beautiful UI Android OS basic screen provides a beautiful and intuitive user interface. Connectivity GSM/EDGE, IDEN, CDMA, EV-DO, UMTS, Bluetooth, Wi-Fi, LTE, NFC and WiMAX. Storage SQLite, a lightweight relational database, is used for data storage purposes. Media support H.263, H.264, MPEG-4 SP, AMR, AMR-WB, AAC, HE-AAC, AAC 5.1, MP3, MIDI, Ogg Vorbis, WAV, JPEG, PNG, GIF, and BMP. Messaging SMS and MMS Web browser Based on the open-source WebKit layout engine, coupled with Chrome's V8 JavaScript engine supporting HTML5 and CSS3. Multi-touch Android has native support for multi-touch which was initially made available in handsets such as the HTC Hero. Multi-tasking User can jump from one task to another and same time various application can run simultaneously. Features of ANDROID Feature Description Resizable widgets Widgets are resizable, so users can expand them to show more content or shrink them to save space. Multi-Language Supports single direction and bi-directional text. GCM Google Cloud Messaging (GCM) is a service that lets developers send short message data to their users on Android devices, without needing a proprietary sync solution. Wi-Fi Direct A technology that lets apps discover and pair directly, over a high- bandwidth peer-to-peer connection. Android Beam A popular NFC-based technology that lets users instantly share, just by touching two NFC-enabled phones together. ANDROID Application Usually developed in the Java language using the Android Software Development Kit (SDK). Can be packaged easily and sold out either through a store such as Google Play or the Amazon Appstore ANDROID Architecture ANDROID Architecture Android operating system is a stack of software components which is roughly divided into five sections and four main layers: Applications Application Framework Libraries (with Android Runtime) Linux Kernel ANDROID Architecture Android provides a set of core applications:  Email Client  SMS Program  Calendar  Maps  Browser  Contacts All applications are written using the Java language. ANDROID Architecture The Application Framework layer provides many higher-level services to applications in the form of Java classes. Application developers are allowed to make use of these services in their applications. Enabling and simplifying the reuse of components. ANDROID Architecture Including a set of C/C++ libraries used by components of the Android system Exposed to developers through the Android application framework A set of libraries including: ⮚ open-source Web browser engine WebKit ⮚ well known library libc ⮚ SQLite database which is a useful repository for storage and sharing of application data, libraries to play and record audio and video ⮚ SSL libraries responsible for Internet security etc. ANDROID Architecture Core Libraries  Providing most of the functionality available in the core libraries of the Java language  APIs  Data Structures  Utilities  File Access  Network Access  Graphics  Etc The Dalvik VM makes use of Linux core features like memory management and multi-threading, which is intrinsic in the Java language. The Dalvik VM enables every Android application to run in its own process, with its own instance of the Dalvik virtual machine. ANDROID Architecture  Relying on Linux Kernel 2.6 for core system services  Memory and Process Management  Network Stack  Driver Model  Security  Providing an abstraction layer between the H/W and the rest of the S/W stack ANDROID Components ANDROID Components Additional Components Component Description s Fragments Represent a behavior or a portion of user interface in an Activity. Views UI elements that are drawn onscreen including buttons, lists forms etc. Layouts View hierarchies that control screen format and appearance of the views. Intents Messages wiring components together. ANDROID STUDIO PANES ANDROID STUDIO PANES PROJECT FILES 1. manifests—Android Manifest file - description of app read by the Android runtime 2. java—Java source code packages 3. res—Resources (XML) - layout, strings, images, dimensions, colors... build.gradle—Contains all the files needed by the build system (learn more about gradle at https://gradle.org/) ANDROID STUDIO PANES PROJECT FILES manifests folder AndroidManifest.xml - describes all of the components of your Android app and is read by the Android run-time system when your program is executed. ANDROID STUDIO PANES PROJECT FILES java folder com.example.hello.helloworld (or the domain name you have specified): All the files for a package are in a folder named after the package. For your Hello World application, there is one package and it only contains MainActivity.java (the file extension may be omitted in the Project view). com.example.hello.helloworld(androidTest): This folder is for your instrumented tests, and starts out with a skeleton test file. com.example.hello.helloworld(test): This folder is for your unit tests and starts out with an automatically created skeleton unit test file. ANDROID STUDIO PANES PROJECT FILES res folder (contains all the resources for your app, including images, layout files, strings, icons, and styling) drawable. Store all your app's images in this folder. layout. Every activity has at least one layout file that describes the UI in XML. For Hello World, this folder contains activity_main.xml. mipmap. Store your launcher icons in this folder. There is a sub-folder for each supported screen density. values. Define the values files instead of hardcoding values like strings, dimensions, and colors in the XML and Java filesThis makes it easier to change and be consistent across your app. ANDROID STUDIO PANES PROJECT FILES values sub-folder colors.xml. Shows the default colors for your chosen theme, and you can add your own colors or change them based on your app's requirements. dimens.xml. Store the sizes of views and objects for different resolutions. strings.xml. Create resources for all your strings. This makes it easy to translate them to other languages. styles.xml. All the styles for your app and theme go here. Styles help give your app a consistent look for all UI elements. ANDROID STUDIO PANES LAYOUT EDITOR ANDROID STUDIO PANES 3 5 4 1 2 6 ANDROID STUDIO PANES Palette 1 Contains various views and view groups that you can drag into your layout. ANDROID STUDIO PANES Component Tree 2 Shows the hierarchy of components in your layout. ANDROID STUDIO PANES 3 Toolbar Contain buttons that configure your layout appearance in the editor and change layout attributes. ANDROID STUDIO PANES 4 Design editor Lets you edit your layout in Design view, Blueprint view, or both. ANDROID STUDIO PANES Attributes 5 Contain controls for the selected view's attributes. ANDROID STUDIO PANES Zoom and pan controls 6 Control the preview size and position within the editor.

Use Quizgecko on...
Browser
Browser