Banner
A banner ad implementation which extends the Android FrameLayout and implements AdLoad and Destroyable interfaces.
General usage of banners:
Moloco.createBanner() instance first
add banner to the view
attach an optional adShowListener
Fetch ortb bid response
load() bid response. AdLoad.Listener or isLoaded can be used for load status check
Once banner is not needed anymore destroy() it to prevent memory leaks
Things to note:
Once banner is loaded it'll automatically display an ad as long as its added to the screen and visible
In order to load an another ad, call load() again provided with a new bid response
load() calls, their amount and order are independent of banner's adding/removal to the view hierarchy; in other words, any order of the mentioned operations is allowed.
Parameters
The activity to which the banner is attached
Samples
com.moloco.sdk.publisher.BannerActivitySampleProperties
The listener to handle banner ad show/hide events
Provides View.isShown latest value and follow-up updates
Functions
Loads the ad with the specified bidResponseJson and listener. If the ad is currently being displayed, the underlying ad object will be destroyed before loading a new one.