Deck 15: In App Advertising

Full screen (f)
exit full mode
Question
The Chronometer class encapsulates the functionality of a running clock.
Use Space or
up arrow
down arrow
to flip the card.
Question
What is the direct superclass of the Chronometer class?

A) Date
B) Time
C) TextView
D) Button
Question
The elapsedRealTime method is static.
Question
What is the return type of the elapsedRealtime method?

A) int
B) short
C) double
D) long
Question
The elapsedRealTime method returns the amount of time since the last boot, including sleep time.
Question
The ____________ class encapsulates a set of marketing characteristics such as location, birthday, and keywords.
Question
It is possible to request an ad to target the demographics related to the app.
Question
To use classes of the com.google.android.gms.ads package, we need to edit the build.gradle file.
Question
The AdView constructor has this API:
public AdView( Context context )
When instantiating an AdView inside a class that extends Activity, we should use ____________ as the argument of the AdView constructor.
Question
When the parent activity of AdView goes in the background, we may want to interrupt the ad loading process; which method of the AdView class can we called?

A) pause
B) sleep
C) goInBackground
D) destroy
Question
The ad unit id of an AdView must be set before an ad can be loaded into the AdView.
Question
It is possible to obtain an ad unit id from Google without being a registered Android developer.
Question
Google provides a test unit id for developers who want to test an app containing an AdView.
Question
The AdRequest class has a static inner class named Builder.
Question
The AdRequest.Builder class includes a method to target the ad based on keywords.
Question
What class encapsulates the size of an ad banner?

A) Size
B) AdSize
C) BannerSize
D) AdBannerSize
Question
Which method of the AdRequest.Builder class returns an AdRequest reference?

A) make
B) create
C) construct
D) build
Question
What constant of the AdSize class do we use so that the height of the ad scales based on the height of the device?

A) AUTO_HEIGHT
B) FULL_WIDTH
C) BANNER
D) SMART_BANNER
Question
What constant of the AdSize class do we use so that the height of the ad is dynamically sized to full width and auto height?

A) AUTO_HEIGHT
B) FULL_WIDTH
C) BANNER
D) SMART_BANNER
Question
When the parent activity of AdView is destroyed, we may want to destroy the AdView and therefore the ad loading process. Which method of the AdView class can we call?

A) interrupt
B) resume
C) stop
D) destroy
Question
It is mandatory to place the code that loads an ad inside a try block (and code the corresponding catch block).
Question
The size of an AdView must be set before an ad can be loaded into the AdView.
Question
To define a drawable with the shape of a circle and define the color inside the circle, we define a __________________ element inside the shape element.
Question
To define a drawable with the shape of a circle and define the color of the outside of the circle, we define a __________________ element inside the shape element.
Question
The setTestDevice method of the AdRequest.Builder class accepts a String parameter; we can call it in order to receive test ads instead of live ads. To use the emulator, we pass the __________________ constant of the AdRequest class.
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/25
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 15: In App Advertising
1
The Chronometer class encapsulates the functionality of a running clock.
True
2
What is the direct superclass of the Chronometer class?

A) Date
B) Time
C) TextView
D) Button
TextView
3
The elapsedRealTime method is static.
True
4
What is the return type of the elapsedRealtime method?

A) int
B) short
C) double
D) long
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
5
The elapsedRealTime method returns the amount of time since the last boot, including sleep time.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
6
The ____________ class encapsulates a set of marketing characteristics such as location, birthday, and keywords.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
7
It is possible to request an ad to target the demographics related to the app.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
8
To use classes of the com.google.android.gms.ads package, we need to edit the build.gradle file.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
9
The AdView constructor has this API:
public AdView( Context context )
When instantiating an AdView inside a class that extends Activity, we should use ____________ as the argument of the AdView constructor.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
10
When the parent activity of AdView goes in the background, we may want to interrupt the ad loading process; which method of the AdView class can we called?

A) pause
B) sleep
C) goInBackground
D) destroy
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
11
The ad unit id of an AdView must be set before an ad can be loaded into the AdView.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
12
It is possible to obtain an ad unit id from Google without being a registered Android developer.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
13
Google provides a test unit id for developers who want to test an app containing an AdView.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
14
The AdRequest class has a static inner class named Builder.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
15
The AdRequest.Builder class includes a method to target the ad based on keywords.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
16
What class encapsulates the size of an ad banner?

A) Size
B) AdSize
C) BannerSize
D) AdBannerSize
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
17
Which method of the AdRequest.Builder class returns an AdRequest reference?

A) make
B) create
C) construct
D) build
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
18
What constant of the AdSize class do we use so that the height of the ad scales based on the height of the device?

A) AUTO_HEIGHT
B) FULL_WIDTH
C) BANNER
D) SMART_BANNER
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
19
What constant of the AdSize class do we use so that the height of the ad is dynamically sized to full width and auto height?

A) AUTO_HEIGHT
B) FULL_WIDTH
C) BANNER
D) SMART_BANNER
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
20
When the parent activity of AdView is destroyed, we may want to destroy the AdView and therefore the ad loading process. Which method of the AdView class can we call?

A) interrupt
B) resume
C) stop
D) destroy
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
21
It is mandatory to place the code that loads an ad inside a try block (and code the corresponding catch block).
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
22
The size of an AdView must be set before an ad can be loaded into the AdView.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
23
To define a drawable with the shape of a circle and define the color inside the circle, we define a __________________ element inside the shape element.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
24
To define a drawable with the shape of a circle and define the color of the outside of the circle, we define a __________________ element inside the shape element.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
25
The setTestDevice method of the AdRequest.Builder class accepts a String parameter; we can call it in order to receive test ads instead of live ads. To use the emulator, we pass the __________________ constant of the AdRequest class.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 25 flashcards in this deck.