AutoLoadBannerPlacement

/**
 * Placement used for obtaining banner ads.
 */
interface AutoLoadBannerPlacement : Placement {
    /**
     * Set the [placement listener][AutoLoadBannerPlacementListener] that will listen to ad loading and display events.
     */
    var listener: AutoLoadBannerPlacementListener?

    /**
     * Sets the [statistics listener][AATKit.StatisticsListener] that will be notified about placement reporting events, like counted adspace, request etc.
     */
    var statisticsListener: AATKit.StatisticsListener?

    /**
     * Sets the [impression listener][ImpressionListener] for the given placement.
     */
    var impressionListener: ImpressionListener?

    /**
     * Setting for Google collapsible banners. Default is null, meaning disabled support for collapsible banners.
     */
    var collapsibleBannerOptions: CollapsibleBannerOptions?

    /**
     * Enables automatic reloading of placement. Autoreloader will use reload time configured on addapptr.com account or fallback to default {@value #BANNER_DEFAULT_RELOAD_INTERVAL_IN_SECONDS} seconds.
     */
    fun startAutoReload()

    /**
     * Disables automatic reloading of placement.
     */
    fun stopAutoReload()

    /**
     * Returns true if there is an ad loaded for given placementId.
     *
     * @return True if there is an ad loaded for given placementId.
     */
    fun hasAd(): Boolean

    /**
     * Returns placement view. Works only for banner placements.
     *
     * @return Placement view or null.
     */
    fun getPlacementView(): View?

    /**
     * Sets placement default image. This image will be shown in placement when no ad is available.
     *
     * @param image       The bitmap to set.
     */
    fun setDefaultImage(image: Bitmap?)

    /**
     * Sets placement default image. This image will be shown in placement when no ad is available.
     *
     * @param resId       The identifier of the resource.
     */
    fun setDefaultImage(resId: Int)

    /**
     * Sets gravity for ads that don't fill entire placement area. Works only for banner placements.
     *
     * @param gravity     The [android.view.Gravity] to set.
     */
    fun setContentGravity(gravity: Int)

    /**
     * Sets the targeting information for the given placement. Information provided for placement overrides targeting information for application set by the [setTargetingInfo].
     */
    var targetingInfo: Map<String, List<String>>?

    /**
     * Sets the content targeting url for the application. This information will be used only if no placement-specific targeting is available.
     *
     * @see .setContentTargetingUrl
     */
    var contentTargetingUrl: String?

    
     /**
     * Sets the multi content targeting url for the application. Not all ad-networks supports multiple urls.
     */
    var multiContentTargetingUrls: List<String>?
}

Last updated