YandexAdsInterstitialComponent constructor

YandexAdsInterstitialComponent({
  1. Function? onAdLoaded,
  2. Function? onAdFailedToLoad,
  3. Function? onAdFailedToShow,
  4. Function? onImpression,
  5. Function? onAdClicked,
  6. Function? onAdShown,
  7. Function? onAdDismissed,
  8. required String id,
})

Implementation

YandexAdsInterstitialComponent({
  Function? onAdLoaded,
  Function? onAdFailedToLoad,
  Function? onAdFailedToShow,
  Function? onImpression,
  Function? onAdClicked,
  Function? onAdShown,
  Function? onAdDismissed,
  required this.id,
}) {
  interstitial = YandexAdsInterstitial();

  FlutterYandexAds.addInterstitial(
    id,
    YandexAdsInterstitialCallbacks(
      onAdLoaded: onAdLoaded,
      onAdFailedToLoad: onAdFailedToLoad,
      onAdFailedToShow: onAdFailedToShow,
      onImpression: onImpression,
      onAdClicked: onAdClicked,
      onAdShown: onAdShown,
      onAdDismissed: onAdDismissed,
    ),
  );

  interstitial.make(id);
}