public class

AppLovinInterstitialAd

extends View
java.lang.Object
   ↳ android.view.View
     ↳ com.applovin.adview.AppLovinInterstitialAd

Class Overview

This class represents an interstitial ad that is rendered on top of the current activity.

Summary

[Expand]
Inherited Constants
From class android.view.View
[Expand]
Inherited Fields
From class android.view.View
Public Methods
static AppLovinInterstitialAdDialog create(AppLovinSdk sdk, Activity activity)
Create a new interstitial dialog that can be shown to the user.
static boolean isAdReadyToDisplay(Activity activity)
Check if an ad is currently preloaded and ready to be displayed.
static void show(Activity activity)
Show a new interstitial ad.
static void show(AppLovinSdk sdk, Activity activity)
Show a new interstitial ad.
[Expand]
Inherited Methods
From class android.view.View
From class java.lang.Object
From interface android.graphics.drawable.Drawable.Callback
From interface android.view.KeyEvent.Callback
From interface android.view.accessibility.AccessibilityEventSource

Public Methods

public static AppLovinInterstitialAdDialog create (AppLovinSdk sdk, Activity activity)

Create a new interstitial dialog that can be shown to the user. This is primarily useful in advanced integrations as the Ad Dialog allows finer control - including manually pre-caching and rendering ads. If all you want to do is show an interstitial the default way, you're looking for show().

Parameters
sdk An SDK instance to use.
activity A non-stale reference to the current top activity.
Returns

public static boolean isAdReadyToDisplay (Activity activity)

Check if an ad is currently preloaded and ready to be displayed. This method wraps the shared SDK instance, and will only work if you declared your SDK key within your Android Manifest.

Returns
  • True if a subsequent call to a show method will result in an immediate display. False if a call to a show method will require network activity first.

public static void show (Activity activity)

Show a new interstitial ad. This method will display a dialog on top of current activity's view with an advertisement in it.

Parameters
activity Parent activity. Must not be null.

public static void show (AppLovinSdk sdk, Activity activity)

Show a new interstitial ad. This method will display a dialog on top of current activity's view with an advertisement in it.

Parameters
sdk AppLovin SDK. Must not be null.
activity Parent activity. Must not be null.