Package com.castlabs.android.adverts

# Class HlsInterstitialPlugin

java.lang.Object
com.castlabs.android.Plugin
com.castlabs.android.adverts.HlsInterstitialPlugin

All Implemented Interfaces:
  `AdProvider`, `ServerAdProvider`

public class HlsInterstitialPlugin extends Plugin implements ServerAdProvider
Plugin that provides HLS interstitial advertisement functionality. This plugin implements the AdProvider interface to handle HLS interstitial ads in the player.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `HlsInterstitialPlugin()`
  Creates a new instance of HlsInterstitialPlugin.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `AdLoader`
  `createAdLoader(PlayerConfig config)`
  Create a server-side `AdLoader` for the provided `PlayerConfig`.
  `String`
  `getId()`
  Returns the ID of the plugin.
  `String`
  `getName()`
  Return a unique name to identify the provider.

  ### Methods inherited from class com.castlabs.android.Plugin

  `init, onRemotePlay`

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### HlsInterstitialPlugin

    public HlsInterstitialPlugin()
    Creates a new instance of HlsInterstitialPlugin. This constructor initializes the plugin for handling HLS interstitial advertisements.

- ## Method Details

  - ### createAdLoader

    @Nullable public AdLoader createAdLoader(@NonNull PlayerConfig config)
    Description copied from interface: `ServerAdProvider`
    Create a server-side `AdLoader` for the provided `PlayerConfig`.
    Specified by:
      `createAdLoader` in interface `ServerAdProvider`
    Parameters:
      `config` - The configuration of the playback session.
    Returns:
      A new `AdLoader` instance, or `null` if the provider cannot serve the configuration.

  - ### getName

    @NonNull public String getName()
    Description copied from interface: `AdProvider`
    Return a unique name to identify the provider.
    Specified by:
      `getName` in interface `AdProvider`
    Returns:
      The provider name.

  - ### getId

    @NonNull public String getId()
    Description copied from class: `Plugin`
    Returns the ID of the plugin. This ID is used to identify the plugin
    Specified by:
      `getId` in class `Plugin`
    Returns:
      The plugin ID or null