public interface BannerAdSession

A provider’s handle for a banner ad. The getView() component is embedded in the Codename One component tree by BannerAd; on a device it wraps a native ad view via a peer component, while in the simulator it is a lightweight placeholder.

This is an internal SPI type.

Methods

public abstract Component getView()The component to embed in the UI, never null.
public abstract void setCallback(AdSessionCallback callback)Registers the callback used to report lifecycle events.
public abstract void load(AdRequest request)Begins loading a banner ad.
public abstract void dispose()Releases native resources held by this session.

Method details

getView

public abstract Component getView()
The component to embed in the UI, never null.

setCallback

public abstract void setCallback(AdSessionCallback callback)
Registers the callback used to report lifecycle events. Called once immediately after creation.

load

public abstract void load(AdRequest request)
Begins loading a banner ad. The request may be null for a default load.

dispose

public abstract void dispose()
Releases native resources held by this session.