Package com.my.target.mediation
Class MyTargetRewardedAdAdapter
- java.lang.Object
-
- com.my.target.mediation.MyTargetRewardedAdAdapter
-
- All Implemented Interfaces:
MediationAdapter,MediationRewardedAdAdapter
public final class MyTargetRewardedAdAdapter extends java.lang.Object implements MediationRewardedAdAdapter
An adapter for internal mediation
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.my.target.mediation.MediationRewardedAdAdapter
MediationRewardedAdAdapter.MediationRewardedAdListener
-
-
Constructor Summary
Constructors Constructor Description MyTargetRewardedAdAdapter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddestroy()Destroys adapter and cleans resources.voiddismiss()Will be called on attempt to dismiss the ad.voidload(MediationAdConfig mediationAdConfig, MediationRewardedAdAdapter.MediationRewardedAdListener listener, android.content.Context context)Will be called when mediation choose this adapter for loading mediation.voidsetSection(InterstitialAdSection section)voidshow(android.content.Context context)Will be called on attempt to show.
-
-
-
Method Detail
-
setSection
public void setSection(@Nullable InterstitialAdSection section)
-
load
public void load(@NonNull MediationAdConfig mediationAdConfig, @NonNull MediationRewardedAdAdapter.MediationRewardedAdListener listener, @NonNull android.content.Context context)Description copied from interface:MediationRewardedAdAdapterWill be called when mediation choose this adapter for loading mediation. All of initialization and loading logic should be implemented here. Then should be calledMediationRewardedAdAdapter.MediationRewardedAdListener.onLoad(MediationRewardedAdAdapter)in case of failed loading should be calledMediationRewardedAdAdapter.MediationRewardedAdListener.onNoAd(IAdLoadingError, MediationRewardedAdAdapter)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.- Specified by:
loadin interfaceMediationRewardedAdAdapter- Parameters:
mediationAdConfig- contains main configuration for mediationlistener- main mediation listenercontext- app context- See Also:
MediationAdConfig
-
show
public void show(@NonNull android.content.Context context)Description copied from interface:MediationRewardedAdAdapterWill be called on attempt to show. Rewarded ad should be displayed here. After successful displaying callbackMediationRewardedAdAdapter.MediationRewardedAdListener.onDisplay(MediationRewardedAdAdapter)should be called- Specified by:
showin interfaceMediationRewardedAdAdapter- Parameters:
context- app context
-
dismiss
public void dismiss()
Description copied from interface:MediationRewardedAdAdapterWill be called on attempt to dismiss the ad. Rewarded ad should be closed here. After closing callbackMediationRewardedAdAdapter.MediationRewardedAdListener.onDismiss(MediationRewardedAdAdapter)should be called- Specified by:
dismissin interfaceMediationRewardedAdAdapter
-
destroy
public void destroy()
Description copied from interface:MediationAdapterDestroys adapter and cleans resources. Adapter will not work after calling this method- Specified by:
destroyin interfaceMediationAdapter
-
-