Bruce Scharlau, University of Aberdeen, 2010 Android UI, and Networking Mobile Computing Based on android-sdk_2.2 Unless otherwise stated, images are from.

Slides:



Advertisements
Similar presentations
Android Application Development A Tutorial Driven Course.
Advertisements

Google Android Introduction to Mobile Computing. Android is part of the build a better phone process Open Handset Alliance produces Android Comprises.
Bruce Scharlau, University of Aberdeen, 2012 Networking for Mobiles Mobile Computing Some slides from MobEduNet This covers HTTP in detail, and mentions.
Bruce Scharlau, University of Aberdeen, 2012 Data storage options for mobiles Mobile Computing.
Bruce Scharlau, University of Aberdeen, 2010 Android and Location Mobile Computing Unless otherwise stated, images are from android sdk.
Bruce Scharlau, University of Aberdeen, 2008 RESTful Assessments.
Ando-it-yourself droid Praveen Kumar Pendyala. Outline Brief intro to the Droid developement Setting up the Life saviors - Development tools Hello Droid.
Android OS : Core Concepts Dr. Jeyakesavan Veerasamy Sr. Lecturer University of Texas at Dallas
CE881: Mobile and Social Application Programming Simon M. Lucas Quiz, Walkthrough, Exercise, Lifecycles, Intents.
CE881: Mobile and Social Application Programming Simon M. Lucas Menus and Dialogs.
Programming with Android: Widgets and Events Luca Bedogni Marco Di Felice Dipartimento di Scienze dell’Informazione Università di Bologna.
All About Android Introduction to Android 1. Creating a New App “These aren’t the droids we’re looking for.” Obi-wan Kenobi 1. Bring up Eclipse. 2. Click.
 User Interface - Raeha Sandalwala.  Introduction to UI  Layouts  UI Controls  Menus and ‘Toasts’  Notifications  Other interesting UIs ◦ ListView.
Filip Debelić What is it? Android is a mobile operating system (OS) based on the Linux kernel and currently developed by Google Android,
1 Frameworks. 2 Framework Set of cooperating classes/interfaces –Structure essential mechanisms of a problem domain –Programmer can extend framework classes,
Android Programming Beomjoo Seo Sep., 12 CS5248 Fall 2012.
INTERNATIONAL SUMMER ACADEMIC COURSE UNIVESITY OF NIS ISAC – Android programming.
Struts. Agenda Preface Struts and its components An example The architecture required for Struts Applications.
Android Application Development 2013 PClassic Chris Murphy 1.
Android UI, and Networking. Can do most networking on Android Bluetooth only on 2.0, Not supported with version 1.6.
CPSC 203 Introduction to Computers Lab 39, 40 By Jie (Jeff) Gao.
Android Boot Camp for Developers Using Java, Comprehensive: A Guide to Creating Your First Android Apps Chapter 9: Customize! Navigating with a Master/Detail.
Android: versions Note that: Honeycomb (Android v3.0) A tablet-only release Jelly Bean (Android v4.1) Released on July 09, 2012.
 Understanding an activity  Starting an activity  Passing information between activities  Understanding intents  Understanding the activity lifecycle.
CS5103 Software Engineering Lecture 08 Android Development II.
© Keren Kalif Intro to Android Development Written by Keren Kalif, Edited by Liron Blecher Contains slides from Google I/O presentation.
ANDROID UI – FRAGMENTS. Fragment  An activity is a container for views  When you have a larger screen device than a phone –like a tablet it can look.
CS378 - Mobile Computing Web - WebView and Web Services.
Chapter 5: Investigate! Lists, Arrays, and Web Browsers.
Chapter 9: Customize! Navigating with Tabs on a Tablet App.
Android development basics Introduction,Structure,Development Boncho Valkov.Net Developer.
Copyright© Jeffrey Jongko, Ateneo de Manila University Android.
Android Boot Camp for Developers Using Java, Comprehensive: A Guide to Creating Your First Android Apps Chapter 5: Investigate! Android Lists, Arrays,
Basic Android Tutorial USF’s Association for Computing Machinery.
ANDROID Presented By Mastan Vali.SK. © artesis 2008 | 2 1. Introduction 2. Platform 3. Software development 4. Advantages Main topics.
This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license, visit
DUE Hello World on the Android Platform.
16 Services and Broadcast Receivers CSNB544 Mobile Application Development Thanks to Utexas Austin.
Asst Prof. Saeed Ahmadi Software Engineering CSF Kabul University 1.
INTRODUCTION TO ANDROID. Slide 2 Application Components An Android application is made of up one or more of the following components Activities We will.
Android Boot Camp for Developers Using Java, 3E
Android Storage. There are several options for storage of data with Android We can put data into a preferences file. We can put data into a ‘normal’ file.
Android – Fragments L. Grewe.
© 2016 Cengage Learning®. May not be scanned, copied or duplicated, or posted to a publicly accessible website, in whole or in part. Android Boot Camp.
MAKANI ANDROID APPLICATION Prepared by: Asma’ Hamayel Alaa Shaheen.
Cosc 4730 Android Fragments. Fragments You can think of a fragment as a modular section of an activity, which has its own lifecycle, receives its own.
User Interface Android GUI Tool OpenGL API XML Writer Optimized Layout Algorithm WPF Component Inter.
Android networking 1. Network programming with Android If your Android is connected to a WIFI, you can connect to servers using the usual Java API, like.
Webview and Web services. Web Apps You can make your web content available to users in two ways in a traditional web browser in an Android application,
HW#9 Clues CSCI 571 Fall, HW#9 Prototype
Recap of Part 1 Terminology Windows FormsAndroidMVP FormActivityView? ControlViewView? ?ServiceModel? Activities Views / ViewGroups Intents Services.
1 Android Development Lean and mean introduction Based on a presentation by Mihail L. Sichitiu.
© 2016 Cengage Learning®. May not be scanned, copied or duplicated, or posted to a publicly accessible website, in whole or in part. Android Boot Camp.
: Information Retrieval อาจารย์ ธีภากรณ์ นฤมาณนลิณี
Class on Fragments & threads. Fragments fragment is a modular section of an activity, which has its own lifecycle, receives its own input events, and.
The Ingredients of Android Applications. A simple application in a process In a classical programming environment, the OS would load the program code.
INTRODUCTION TO ANDROID. Slide 2 Introduction I take a top-down approach to describing an application’s anatomy.
USING ANDROID WITH THE INTERNET. Slide 2 Lecture Summary Getting network permissions Working with the HTTP protocol Sending HTTP requests Getting results.
Chapter 5: Investigate! Lists, Arrays, and Web Browsers.
Why Learn Android? Largest installation base of any operating system Over 20,000 Android devices exist Businesses will likely move more to device-based.
Progress Apama Fundamentals
Open Handset Alliance.
Android Studio, Android System Basics and Git
Activities and Intents
Android SDK & App Development
Android Developer Fundamentals V2 Lesson 1
Software Engineering for Internet Applications
Activities and Intents
Android Developer Fundamentals V2
Android Topics Threads and the MessageQueue
Presentation transcript:

Bruce Scharlau, University of Aberdeen, 2010 Android UI, and Networking Mobile Computing Based on android-sdk_2.2 Unless otherwise stated, images are from android sdk

Proxy issues while in eduroam May need page as intermediary for accessing other services with emulator in Java ME or Android Bruce Scharlau, University of Aberdeen, 2010 PHP/JSP page Desired web service web form can be configured to use proxy

Can do most networking on Android Bluetooth only on 2.0 onwards – look at that later. Bruce Scharlau, University of Aberdeen, 2010

Android has many components

All layouts are hierarchical Bruce Scharlau, University of Aberdeen, 2010

All screens are derived from view Bruce Scharlau, University of Aberdeen, 2010 Source: unlocking android, p 71

Hierarchical views can include similar groups Bruce Scharlau, University of Aberdeen, 2010

Children do as told in Android Bruce Scharlau, University of Aberdeen, 2010 TextView is child of parent viewgroup and fills, or wraps content

There are many types of controls in Android Bruce Scharlau, University of Aberdeen, 2010

Lists can be handled via adapters and filled from xml file of values Bruce Scharlau, University of Aberdeen, 2010

Table layout allows for just that with data Bruce Scharlau, University of Aberdeen, 2010

Use the hierarchy viewer tool to optimize and debug interface Bruce Scharlau, University of Aberdeen,

Views are tied to activities (screens) in Android Bruce Scharlau, University of Aberdeen, 2010 Source: unlocking android, p 60 One class per activity, and screen, which may be done as xml file

One layout per activity (class) Bruce Scharlau, University of Aberdeen, 2010 main.xml goes with AuctionStart list.xml goes with ListItems hit_server.xml goes with HitServer

Xml layout file details components Bruce Scharlau, University of Aberdeen, 2010 Hierarchy of views as noted earlier

Xml layout inflated in onCreate Bruce Scharlau, University of Aberdeen, 2010 Set value of inflated object INCOMPLETE CODE New view items and attached to xml values

Bruce Scharlau, University of Aberdeen, 2010 Android emulator runs as localhost, ie loopback Emulator is at so need to call service at IP address of service to test network apps on developer machine

Bruce Scharlau, University of Aberdeen, 2010 Activity is one thing you can do From fundamentals page in sdk

Apps move through states during lifecycle Bruce Scharlau, University of Aberdeen, 2010 Source: unlocking android, p 68 onPause is last state to preserve state and cleanup before app possibly destroyed

Handler class provides access to running thread for main UI Bruce Scharlau, University of Aberdeen, 2010 Handler has Looper which contains MessageQueue that can be called and return objects to UI thread

Handler puts thread response into UI thread Bruce Scharlau, University of Aberdeen, 2010 Source: unlocking android, p 180

Method returns string from network Bruce Scharlau, University of Aberdeen, 2010 Log output for debugging, etc Simple method to call URL and return value

Might need helper calls to network Bruce Scharlau, University of Aberdeen, 2010 Put heavy lifting work in HTTPRequestHelper so accessible to other classes Handler waits for message and then returns

Parse xml response and populate Java bean instance Bruce Scharlau, University of Aberdeen, 2010

Add permissions to manifest for connection and network Bruce Scharlau, University of Aberdeen, 2010

Summary Need to provide permissions for network in manifest Create tree of xml views for UI Can re-use xml views for different displays Bruce Scharlau, University of Aberdeen, 2010