-
- All Implemented Interfaces:
@MainThread() public class NativeAdLoader
Class containing controls for native ad loading.
-
-
Constructor Summary
Constructors Constructor Description NativeAdLoader(Context context)Constructs a new NativeAdLoader with specific configuration.
-
Method Summary
Modifier and Type Method Description voidsetNativeAdLoadListener(@Nullable() NativeAdLoadListener listener)Register a callback for listening native ad loader. voidloadAd(@NonNull() NativeAdRequestConfiguration nativeAdRequestConfiguration)Start loading the native ad by NativeAdRequestConfiguration on a background thread. voidcancelLoading()Cancel loading the native ad. -
-
Constructor Detail
-
NativeAdLoader
NativeAdLoader(Context context)
Constructs a new NativeAdLoader with specific configuration.- Parameters:
context- The activity context used to retrieve the application context.
-
-
Method Detail
-
setNativeAdLoadListener
void setNativeAdLoadListener(@Nullable() NativeAdLoadListener listener)
Register a callback for listening native ad loader.
- Parameters:
listener- an NativeAdLoadListener object that handles lifecycle native ad.
-
loadAd
void loadAd(@NonNull() NativeAdRequestConfiguration nativeAdRequestConfiguration)
Start loading the native ad by NativeAdRequestConfiguration on a background thread.
- Parameters:
nativeAdRequestConfiguration- an NativeAdRequestConfiguration object contains targeting information used to fetch a native ad.
-
cancelLoading
void cancelLoading()
Cancel loading the native ad.
-
-
-
-