mobile programming practice - skkuarcs.skku.edu/pmwiki/uploads/courses/swpractice3/01... ·...

26
Mobile Programming Practice Course Overview Lecture Schedule Contact Today’s Task 1 Prof. Hwansoo Han T.A. Sung-in Hong

Upload: others

Post on 10-Mar-2020

19 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Mobile Programming Practice

▪ Course Overview

▪ Lecture Schedule

▪ Contact

▪ Today’s Task

1

Prof. Hwansoo Han

T.A. Sung-in Hong

Page 2: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Course Overview

▪ Lecture + Lab

• Lecture: ~1 hour basic Android features

• Lab: ~2.5 hours programming practices

▪ Programming projects

• Almost 10 lab practices

• 2 assignments

• 1 term project (2-3 in a team)

• No exams

2

Page 3: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Course Overview

▪ Prerequisites

• Introduction to computer science

• ***Experience of Java programming***

• Data structure

▪ Grading factors

• Attendance 10%

• Lab practice 10%

• Assignment 40%

• Term Project (proposal 10% + final 30%)

3

Page 4: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Grading Policy

▪ Must – otherwise you will get ‘F’ grade

• Submit two programming assignments

• Submit term project assignment

▪ You will also get ‘F’ if you…

• Absent more than 3 times

• Attending after lecture will be counted by late (2 lates = 1 absence)

• Turn in a completely duplicated assignment

• Allow another student to turn in your work as his/her own

4

Page 5: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Lecture Schedule

Spring 2019 (Tuesday)

This schedule can be changed

M

A

R

C

H

5 12 19 26

IntroductionAndroid overview

& basic layoutLayout Advanced UI

A

P

R

I

L

2 9 16 23 30

Broadcast receivers

PA#1Services Project proposal

MID TERM

(no exam)

Content providers

M

A

Y

7 14 21 28

Advanced concepts

(1)

APIs (1)

PA#2APIs (2) Profile

J

U

N

E

4 11 18

Intro. to the Kotlin

Project

Final

Presentation

END TERM

(no class)

5

Page 6: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Contact

▪ Office (컴파일러및시스템연구실)

• 85565, Corporate Collaboration Center

▪ TA

• Sung-in Hong

[email protected]

▪ Feel free to contact me by e-mail

6

Page 7: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Today’s Task

▪ Briefly understanding Android

▪ Install Android Studio on Microsoft Windows

• Ask TA if you do on Ubuntu or other with your laptop

• Highly recommended to use Intel. CPU

▪ Run your app on Android Studio

7

Page 8: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Android OS

▪ A mobile operating system developed by Google

▪ Based on a modified version of the Linux kernel

and other open source softwares

▪ A multi-user Linux system in which app is a

different user

▪ Designed primarily for touchscreen mobile

devices such as smartphone and tablets

▪ Android history:

• https://www.android.com/history/#/marshmallow

8

Page 9: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Android architecture

9

Ref. : The impact of Big Data on the Android Mobile Platform for Natural Disaster

Situations - Scientific Figure on ResearchGate. Available from:

https://www.researchgate.net/figure/Android-Architecture-2_fig1_322941237 [accessed

4 Mar, 2019]

Page 10: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Android application

▪ Can be written using Kotlin, Java, and C++

languages.

▪ The Android SDK tools compile your code with any

data and resource files into APK an archive file with

an .apk suffix

▪ Each Android app lives in its own security sandbox,

protected by Android security features

• More info.

https://developer.android.com/guide/components/fundamental

s.html

10

Page 11: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Glossary of Android

▪ Component

• The essential building blocks of an Android app.

• Activities, services, broadcast receivers, and

content providers

▪ Activity

• The end point for interacting with the user

▪ Service

• A general-purpose entry point for keeping an app

running in the background for all kinds of reasons.

11

Page 12: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Glossary of Android

▪ Broadcast receiver

• A component that enables the system to deliver

events to the app outside of a regular user flow,

allowing the app to respond to system-wide

broadcast announcements.

▪ Content provider

• A content provider manages a shared set of app data

that you can store in the file system, in a SQLite

database, on the web, or on any other persistent

storage location that your app can access.

12

Page 13: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Glossary of Android

▪ Fragment

• Represents a portion of user interface in an Activity

▪ View

• The basic building block for user interface

• Buttons, lists forms, etc.

▪ Layout

• Visual arrangement of containers and views

▪ Intent

• Messages wiring components together

13

Page 14: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Glossary for beginners

▪ https://developers.google.com/android/for

-all/vocab-words/?hl=en

▪ This glossary of Android and Java vocab

words supplements the Udacity Android for

Beginners course. This course is targeted at

those who are new to programming but want

to start building Android apps.

14

Page 15: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Android Studio

▪ Android Studio is the official Integrated

Development Environment (IDE) for Android

app development, based on IntelliJ IDEA

▪ https://developer.android.com/studio

15

Page 16: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Installation

16

Download link : https://developer.android.com/studio

For windows 64bit

For other options

Page 17: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

[Lab – Practice #0]

▪ edu.skku.cs.MyFirstApp

• Create new project wich contains basic Activity

17

Page 18: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

APPENDIX A –

how to install Java on Windows

18

Page 19: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

How to install Java

19

https://www.oracle.com

Page 20: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

How to install Java

20

Page 21: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

How to install Java

21

Page 22: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

How to install Java

22

Detailed guide:

https://wiki.appcelerator.org/display/guides2/Installing+Oracle+JDK

Page 23: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Set Environment Variable

1. [Win_key + R]

2. Type “sysdm.cpl” and press enter

23

Detailed guide:

http://stackoverflow.com/questions/2619584/how-to-set

-java-home-on-windows-7

Page 24: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Set Environment Variable

3. Move to “Advanced” tab

4. Click Environment Variables

24

Page 25: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Set Environment Variable

5. Click “New…”

6. Create variable “JAVA_HOME”

with the Java Installation Path

25

Page 26: Mobile Programming Practice - SKKUarcs.skku.edu/pmwiki/uploads/Courses/SWPractice3/01... · 2019-03-05 · Mobile Programming Practice ... Install Android Studio on Microsoft Windows

Set Environment Variable

7. Also create variable “CLASSPATH”

by “%JAVA_HOME%\jre\lib”

8. Modify variable “Path”

by adding “%JAVA_HOME%\bin”

26