| java.lang.Object | |
| ↳ | com.applovin.mediation.ads.MaxRewardedAd |
This class represents a full screen rewarded ad.
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| void |
destroy()
Destroy current ad and fully remove it from memory.
| ||||||||||
| static MaxRewardedAd |
getInstance(String adUnitId, Activity activity)
Get an instance of rewarded ad.
| ||||||||||
| static MaxRewardedAd |
getInstance(String adUnitId, AppLovinSdk sdk, Activity activity)
Get an instance of rewarded ad.
| ||||||||||
| boolean |
isReady()
Check if this ad is ready to be shown.
| ||||||||||
| void |
loadAd()
Load ad for the current rewarded ad.
| ||||||||||
| void |
setExtrasParameter(String key, String value)
Set an extra parameter to pass to AppLovin server.
| ||||||||||
| void |
setListener(MaxRewardedAdListener listener)
Set a listener that will be notified about ad display events (i.e.
| ||||||||||
| void |
showAd()
Show the loaded rewarded ad.
| ||||||||||
| void |
showAd(String placement)
Show the loaded rewarded ad for a given placement to tie ad events to.
| ||||||||||
| String | toString() | ||||||||||
| static void |
updateActivity(Activity activity)
Update currently active activity.
| ||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
Destroy current ad and fully remove it from memory.
Get an instance of rewarded ad.
| adUnitId | Ad unit id for which to get the instance. Must not be null. |
|---|---|
| activity | Currently active activity. Must not be null. |
Get an instance of rewarded ad.
| adUnitId | Ad unit id for which to get the instance. Must not be null. |
|---|---|
| sdk | Max ads SDK. Must not be null. |
| activity | Currently active activity. Must not be null. |
Check if this ad is ready to be shown.
true if the ad is ready to be shown.
Load ad for the current rewarded ad. Use setListener(MaxRewardedAdListener) to assign a listener that should be notified about ad load state.
Set an extra parameter to pass to AppLovin server.
| key | Parameter key. Must not be null. |
|---|---|
| value | Parameter value. May be null. |
Set a listener that will be notified about ad display events (i.e. ad shown, hidden, etc.)
| listener | Listener to be notified. May be null. |
|---|
Show the loaded rewarded ad.
Use setListener(MaxRewardedAdListener) to assign a listener that should be notified about display events.
Use isReady() to check if an ad was successfully loaded.
Show the loaded rewarded ad for a given placement to tie ad events to.
Use setListener(MaxRewardedAdListener) to assign a listener that should be notified about display events.
Use isReady() to check if an ad was successfully loaded.
| placement | The placement to tie the showing ad's events to. |
|---|
Update currently active activity. This activity will be used to load new rewarded ads.
Note that Max Rewarded holds a weak reference to the activity.
| activity | New activity to use. Must not be null. |
|---|