1/15
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
intent filter
each activity describes the intents it offers in the app manifest file (XML). when an app requests an activity, it issues a startActivity() call requesting an intent
how does android handle the “what is being done” part
using a registry of intents
intent
messaging object used to request an action from another app component
open intent pro 1
new features can be added after design
open intent pro 2
loose coupling
open intent con 1
no guarantees
open intent con 2
there may be no provider capable of providing the open intent desired function
service providing intent example
text to speech provider. different instances for different languages, speech styles, voices, etc
discovery start
at installation, each new app registers its intents with the OS. new providers become known when they’re installed
lifecycle
each activity has a defined lifecycle delimited by calls to event handlers
android issue 1
no provider for an intent
android solution 1
don’t offer the option to the user
android issue 2
many possible providers
android solution 2
ask the user to choose
android issue 3
component crashes
android solution 3
revert to the calling activity/ fail/ home screen