Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android fundamentals #11

Open
eldenpark opened this issue Oct 13, 2018 · 0 comments
Open

Android fundamentals #11

eldenpark opened this issue Oct 13, 2018 · 0 comments

Comments

@eldenpark
Copy link
Contributor

eldenpark commented Oct 13, 2018

procedural programming v. Declarative programming 선언적 프로그래밍

procedural programming 절차적 프로그래밍: 거의 대부분의 절차를 개발자가 정의
선언적 프로그래밍은: 일부만 정의

  • why
  • how's it related to Android?

three core concepts of android app

  • components (5)
  • manifest
  • resources

android components

  • activity
    UI
    AndroidFragments

  • Service
    long running operations
    thread vs service
    track the state of operation
    e.g. music player
    monolithic v. modular architecture

  • Broadcast receiver
    stateless, onReceive()
    delegate call to another component, e.g. Context.startActivity(), Context.startService()
    listening to system events

  • Content providers
    sharing data with other applications as well
    simple key/value pairs => prefer using SharedPreferences
    if having structured data, consider using Database

Last but not least

  • application
    Always only a single instance within an application, use this to keep global variables

manifest

  • top level element
<manifest/>
  • Google Play filters
<uses-feature/>
<supports-screen/>
<uses-sdk/>
<application/>
  • Intent filtering
    abstract description of operation
    explicit Intent: know exactly what activity to startActivity
    implicit Intent: only the action
    pending intent*

Resources

<string/>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant