Class MyTargetInterstitialAdAdapter
-
- All Implemented Interfaces:
-
com.my.target.mediation.MediationAdapter,com.my.target.mediation.MediationInterstitialAdAdapter
public final class MyTargetInterstitialAdAdapter implements MediationInterstitialAdAdapter
An adapter for internal mediation
-
-
Constructor Summary
Constructors Constructor Description MyTargetInterstitialAdAdapter()
-
Method Summary
Modifier and Type Method Description voiddestroy()Destroys adapter and cleans resources. voiddismiss()Will be called on attempt to dismiss the ad. voidload(@NonNull() MediationAdConfig mediationAdConfig, @NonNull() MediationInterstitialAdAdapter.MediationInterstitialAdListener listener, @NonNull() Context context)Will be called when mediation choose this adapter for loading mediation. voidshow(@NonNull() Context context)Will be called on attempt to show. -
-
Method Detail
-
destroy
void destroy()
Destroys adapter and cleans resources. Adapter will not work after calling this method
-
dismiss
void dismiss()
Will be called on attempt to dismiss the ad. Interstitial ad should be closed here. After closing callback MediationInterstitialAdListener.onDismiss(MediationInterstitialAdAdapter) should be called
-
load
void load(@NonNull() MediationAdConfig mediationAdConfig, @NonNull() MediationInterstitialAdAdapter.MediationInterstitialAdListener listener, @NonNull() Context context)
Will be called when mediation choose this adapter for loading mediation. All of initialization and loading logic should be implemented here. Then should be called MediationInterstitialAdAdapter.MediationInterstitialAdListener.onLoad(MediationInterstitialAdAdapter) in case of failed loading should be called MediationInterstitialAdAdapter.MediationInterstitialAdListener.onNoAd(IAdLoadingError, MediationInterstitialAdAdapter) with the reason of fail. If no callbacks will be called, adapter will be removed from loading queue, and next adapter or no ad will be called.
- Parameters:
mediationAdConfig- contains main configuration for mediationlistener- main mediation listenercontext- app context
-
show
void show(@NonNull() Context context)
Will be called on attempt to show. Interstitial ad should be displayed here. After successful displaying callback MediationInterstitialAdListener.onDisplay(MediationInterstitialAdAdapter) should be called
- Parameters:
context- app context
-
-
-
-