InterstitialAd
Last updated
Last updated
package com.intowow.sdk
public class InterstitialAd extends Ad
Takes up the whole screen. Users could engage with the ad or close the ad and back to app.
Support portrait and landscape mode.
Support image and video.
Video is mute by default, and can be toggled by clicking it.
Declare InterstitialAdActivity to AndroidManifest.xml
You could request an ad by:
remember to release ad if it is no longer to use.
Public constructors
Public methods
void
void
void
Load ad with requestInfo (asynchronous)
void
void
void
void
Inherited methods
int
String
String
int
String
Rect
String
long
String
boolean
boolean
void
InterstitialAd(Context context)
Instantiates a new interstitial ad.
Parameters
context
Context: the context.
void close()
Close the InterstitialActivity directly.
void destroy()
Release the ad.
Load ad with RequestInfo (synchronous)
Parameters
requestInfo
Load ad with RequestInfo (asynchronous)
Parameters
requestInfo
listener
Set the ad listener.
Parameters
listener
void setAutoCloseWhenEngaged(boolean isAutoClose)
Instruct SDK to close the interstitial ad after user clicks the ad. You should call this method before loadAdInstant/loadAdAsync if necessary.
Parameters
isAutoClose
boolean: if auto close when ad is engaged or not.
void show()
Start the InterstitialActivity. You should call this method after onAdLoaded().
void show(int enterAnim, int exitAnim)
Start the InterstitialActivity with animation effect. You should call this method after onAdLoaded().
Parameters
enterAnim
int: A resource ID of the animation resource to use for the incoming activity. Use 0 for no animation.
exitAnim
int: A resource ID of the animation resource to use for the outgoing activity. Use 0 for no animation.
If you want the ad to enter the screen with animation effect, please use after ad loaded.
If you want to close the interstitial ad after user clicks the ad, please use before you call /.
Instantiates a new interstitial ad.
Instantiates a new interstitial ad.
Close the InterstitialActivity directly.
Release the interstitial ad.
Load ad with requestInfo (synchronous)
Set the ad listener.
Instruct SDK to close the interstitial ad after user clicks the ad. You should call this method before loadAdInstant/loadAdAsync if necessary.
Start the InterstitialActivity. You should call this method after onAdLoaded().
Start the InterstitialActivity with animation effect. You should call this method after onAdLoaded().
Get the ad id.
Get the campaign id.
Get the engage url.
Get the ad place.
Get the ad placement.
Get the ad size. It should be called after onAdLoaded().
Get the ad token for tracking.
Get the ad file size on device.
Get video cover file path. It should be called after onAdLoaded().
Check if the ad has video content or not.
Check if the ad is still valid for serving.
Set the ad size.
loadAdInstant(RequestInfo requestInfo)
: the request info such as placement and timeout.
void loadAdAsync(RequestInfo requestInfo,r listener)
: the request info such as placement and timeout.
: know the result of loadAdAsync
void setAdListener( listener)
: the ad listener.