Flutter - Monetize App SDK Documentation

⌘K
  1. Flutter – Monetize ...
  2. Formatos de Anúncio
  3. Intersticial

Intersticial

Full-screen ads that cover the interface of an app until closed by the user. They’re best used at natural pauses in the flow of an app’s execution, such as in between levels of a game or just after completing a task.

Show the Ad

Call createInterstitial method from RefinariaAdFactory to display interstitial ads by providing the configurationId.

R89SDK.adFactory.createInterstitial(
    configurationId: ConfigBuilder.interstitialTestR89ConfigId);

Eventos do Ciclo de Vida

To receive lifecycle events, provide InterstitialEventListener to R89SDK.adFactory.createInterstitial via callbacksLifecycle parameter. Details about InterstitialEventListener can be found in the Reference.

R89SDK.adFactory.createInterstitial(
    configurationId: ConfigBuilder.interstitialTestR89ConfigId,
    lifecycleCallbacks: InterstitialEventListener.callbacks(
        onLoadedCallback: () {},
        onOpenCallback: () {},
        onImpressionCallback: () {},
        onClickCallback: () {},
        onFailedToLoadCallback: (error) {},
        onAdFailedToShowFullScreenCallback: (error) {}));

To receive an interstitial close event, provide the apósIntersticial callback to R89SDK.adFactory.createInterstitial método.

R89SDK.adFactory.createInterstitial(
  configurationId: ConfigBuilder.interstitialTestR89ConfigId,
  lifecycleCallbacks: InterstitialEventListener.callbacks(
      onLoadedCallback: () {},
      ...
      onAdFailedToShowFullScreenCallback: (error) {}),
  afterInterstitial: () {
      // Close event
  },
);

O apósIntersticial callback is not passed as a separate object like the other Events because it is mandatory to handle what happens after an Interstitial is closed.
The following is invoked in the SDK when:

  • The user just closed the full-screen ad.
  • O anúncio não pôde ser exibido.

Como podemos ajudar?