Lesson 1 Flashcards
Create Project Sunshine
Project Structure (cmd ;), ->app -> flavors
versions
AVD
Android Virtual Device
stack
application layer, application framework, c/c++ libs & Android Runtime, Linux Kernel
ADB
Android Debug Bridge
ADB commands
push, pull, shell, logcat…
gradle task
atomic work for build
./gradlew tasks
run on command line to list runnable gradle tasks
adb list commands
enter adb into terminal
Apps are…
collections of connected components
4 types of app components
Activity, Service, Content Provider, Broadcast Receiver (BACS) | (Br, A,S,Cp)
Android Manifest does what with components?
Register components
Activity
Component responsible for user interaction (view); a “single focused thing the user can do”.
Responsible for creating the window the application uses to draw and receive events from the system.
Experience of App, Activities
Experience app as a sequence of activities, beginning with launcher. Kept as a stack.
Android Manifest’s launcher
launch tag for application. Registered to an activity, with an intent filter for launching.
what layout does for activity
layout contains information about what to display, and how to display it.
res folder
application resources
resources
strings, images, files, layouts
layout file
xml format, contains view objects
onCreate in java activity, layout
setContentView to some layout; “inflates layout… Android reads your XML file and generates Java objects for each of the tags in your layout file”; i.e. instantiates layout
views
created by activity to show information, and be interacted with. Rectangular area responsible for drawing and handling events.
xml layout file; for activity, stored where
how an activity determines what views to create + where to put them. Stored in res folder “layouts”
UI components
view type that’s often interacted with. E.g. TextView, EditText, ImageView, Button, Chronometer
Layout/Container_View
typically contain group of views, determine position. E.g. LinearLayout, RelativeLayout, FrameLayout, ScrollView, ConstraintLayout
wrap_content
shrink view to wrap whatever is inside the view