-
- All Implemented Interfaces:
@MainThread() public interface NativeAd
Interface allows to set NativeAdEventListener and to define whether web links are opened by in-app browser or by third-party browsers.
-
-
Method Summary
Modifier and Type Method Description abstract voidbindNativeAd(@NonNull() NativeAdViewBinder viewBinder)Bind view with native ad's content. abstract voidsetNativeAdEventListener(@Nullable() NativeAdEventListener eventListener)Sets an NativeAdEventListener. abstract NativeAdAssetsgetAdAssets()Returns ad assets. abstract NativeAdTypegetAdType()Returns native ad type ResponseNativeType. abstract StringgetInfo()Information field for IMAGE ad abstract voidloadImages()Asynchronously loads ad's images. abstract voidaddImageLoadingListener(@NonNull() NativeAdImageLoadingListener listener)Adds listener for receiving notifications about images loading progress. abstract voidremoveImageLoadingListener(@NonNull() NativeAdImageLoadingListener listener)Removes listener, so it's no longer notified about images loading progress. -
-
Method Detail
-
bindNativeAd
abstract void bindNativeAd(@NonNull() NativeAdViewBinder viewBinder)
Bind view with native ad's content.
- Parameters:
viewBinder- An NativeAdViewBinder object.
-
setNativeAdEventListener
abstract void setNativeAdEventListener(@Nullable() NativeAdEventListener eventListener)
Sets an NativeAdEventListener.
- Parameters:
eventListener- NativeAdEventListener.
-
getAdAssets
@NonNull() abstract NativeAdAssets getAdAssets()
Returns ad assets.
-
getAdType
@NonNull() abstract NativeAdType getAdType()
Returns native ad type ResponseNativeType.
-
loadImages
abstract void loadImages()
Asynchronously loads ad's images. Every loaded image is set to corresponding ImageView. Images are not persisted in memory and should be loaded each time ad is being bound. Typically, every bind call should be followed by loadImages call, if automatic image loading is disabled in NativeAdRequestConfiguration.
-
addImageLoadingListener
abstract void addImageLoadingListener(@NonNull() NativeAdImageLoadingListener listener)
Adds listener for receiving notifications about images loading progress.
- Parameters:
listener- Image loading listener.
-
removeImageLoadingListener
abstract void removeImageLoadingListener(@NonNull() NativeAdImageLoadingListener listener)
Removes listener, so it's no longer notified about images loading progress.
- Parameters:
listener- Image loading listener.
-
-
-
-