Interface MediationNativeAdAdapter.MediationNativeAdListener

Enclosing interface:
MediationNativeAdAdapter

public static interface MediationNativeAdAdapter.MediationNativeAdListener
  • Method Details

    • onAdChoicesIconLoad

      void onAdChoicesIconLoad(@Nullable ImageData imageData, boolean success, @NonNull MediationNativeAdAdapter adapter)
      Need to call when adChoices icon loaded successfully
      Parameters:
      imageData - is current instance
      success - is download status
      adapter - an instance of current adapter
    • onLoad

      void onLoad(@NonNull NativePromoBanner banner, @NonNull MediationNativeAdAdapter adapter)
      Must be called when implemented ads network loads successfully inside MediationNativeAdAdapter.load(MediationNativeAdConfig, MediationNativeAdListener, Context) method.
      Parameters:
      banner - banner should be created from assets, received from ad network. Use NativePromoBanner.Builder for building it
      adapter - an instance of current adapter
    • onNoAd

      void onNoAd(@NonNull IAdLoadingError adLoadingError, @NonNull MediationNativeAdAdapter adapter)
      Must be called when implemented ads failed to load for some reason inside MediationNativeAdAdapter.load(MediationNativeAdConfig, MediationNativeAdListener, Context) method.
      Parameters:
      adLoadingError - a reason of fail to load
      adapter - an instance of current adapter
    • onClick

      void onClick(@NonNull MediationNativeAdAdapter adapter)
      Must be called when ad view received click. Most of ad networks provide callbacks for this, so pass it here
      Parameters:
      adapter - an instance of current adapter
    • onShow

      void onShow(@NonNull MediationNativeAdAdapter adapter)
      Must be called when ad view showing / impression must be tracked. Most of ad networks provide callbacks for this, so pass it here
      Parameters:
      adapter - an instance of current adapter
    • onVideoPlay

      void onVideoPlay(@NonNull MediationNativeAdAdapter adapter)
      If current ad contains video element, must be called when video starts playing
      Parameters:
      adapter - an instance of current adapter
    • onVideoPause

      void onVideoPause(@NonNull MediationNativeAdAdapter adapter)
      If current ad contains video element, must be called when video paused
      Parameters:
      adapter - an instance of current adapter
    • onVideoComplete

      void onVideoComplete(@NonNull MediationNativeAdAdapter adapter)
      If current ad contains video element, must be called when video completed playing
      Parameters:
      adapter - an instance of current adapter
    • shouldCloseAutomatically

      boolean shouldCloseAutomatically()
      Determines what SDK should do when selecting particular adchoices option.
      Returns:
      Boolean value which specifies should be ad closed or not.
    • onCloseAutomatically

      void onCloseAutomatically(@NonNull MediationNativeAdAdapter adapter)
      Calls if shouldCloseAutomatically() returned true.
      Parameters:
      adapter - Adapter whom ad was closed automatically.
    • closeIfAutomaticallyDisabled

      void closeIfAutomaticallyDisabled(@NonNull MediationNativeAdAdapter adapter)
      Calls if shouldCloseAutomatically() returned false.
      Parameters:
      adapter - Adapter whom ad have to be hidden.