IconAd

interface IconAd : Ad


An ad that highlights an app icon. This ad is composed of ad assets which are displayed as Android UI components.

Summary

Public companion functions

suspend AdLoadResult<IconAd>
load(adRequest: IconAdRequest)

Loads an IconAd, suspending until an IconAd successfully loads or fails to load.

Unit
load(adRequest: IconAdRequest, adLoadCallback: AdLoadCallback<IconAd>)

Loads an IconAd, providing the result via adLoadCallback.

Unit
loadFromAdResponse(
    adResponse: String,
    adLoadCallback: AdLoadCallback<IconAd>
)

Loads an IconAd, providing the result via adLoadCallback.

Public properties

AdChoicesInfo?

The information for the AdChoices attribution.

IconAdEventCallback?

Callback for receiving icon ad lifecycle events.

String?

The ad's call to action (such as "Buy" or "Install").

String?

The primary text headline.

Image

An image for the icon.

Double?

A star rating from 0 to 5 representing how many stars the app has in the store offering it.

Inherited functions

From com.google.android.libraries.ads.mobile.sdk.common.Ad
Unit

Destroys the ad, stopping any extra processing and destroying resources associated with the ad.

ResponseInfo

Gets information about the ad response for this ad.

Inherited properties

From com.google.android.libraries.ads.mobile.sdk.common.Ad
Long

An identifier for a placement in reporting.

Public companion functions

load

suspend fun load(adRequest: IconAdRequest): AdLoadResult<IconAd>

Loads an IconAd, suspending until an IconAd successfully loads or fails to load.

Parameters
adRequest: IconAdRequest

An IconAdRequest with targeting information.

Returns
AdLoadResult<IconAd>

AdLoadResult.Success if the load succeeded, AdLoadResult.Failure otherwise.

load

fun load(adRequest: IconAdRequest, adLoadCallback: AdLoadCallback<IconAd>): Unit

Loads an IconAd, providing the result via adLoadCallback.

Parameters
adRequest: IconAdRequest

An IconAdRequest with targeting information.

adLoadCallback: AdLoadCallback<IconAd>

A callback to be invoked when loading completes.

loadFromAdResponse

fun loadFromAdResponse(
    adResponse: String,
    adLoadCallback: AdLoadCallback<IconAd>
): Unit

Loads an IconAd, providing the result via adLoadCallback.

Parameters
adResponse: String

An ad response from a server-to-server ad request.

adLoadCallback: AdLoadCallback<IconAd>

A callback to be invoked when loading completes.

Public properties

adChoicesInfo

val adChoicesInfoAdChoicesInfo?

The information for the AdChoices attribution.

adEventCallback

var adEventCallbackIconAdEventCallback?

Callback for receiving icon ad lifecycle events.

callToAction

val callToActionString?

The ad's call to action (such as "Buy" or "Install").

headline

val headlineString?

The primary text headline.

icon

val iconImage

An image for the icon.

starRating

val starRatingDouble?

A star rating from 0 to 5 representing how many stars the app has in the store offering it.