CENativeAd
Overview
CENativeAd
is used to request and manage native ad, which contains many parameters for building custom UI with CEMediaView
.
Interface
placement
placement
Declaration
Discussion
Placement id which is used to require ad.
title
title
Declaration
Discussion
An optional string describing the title of the native ad.
subTitle
subTitle
Declaration
Discussion
An optional string describing the subtitle of the native ad.
callToAction
callToAction
Declaration
Discussion
An optional string describing the call to action slogan of the native ad. This is usually used to decorate the call-to-action button.
icon
icon
Declaration
Discussion
A CEAdImage
object, which is used to get the icon image of the native ad.
body
body
Declaration
Discussion
An optional string describing the main description of the native ad.
adToken
adToken
Declaration
Discussion
A random identifier string generated by SDK.
eventDelegate
eventDelegate
Declaration
Discussion
Delegate which is notified by SDK when CENativeeAd
triggered the ad event.
ad
ad
Declaration
Discussion
An Ad
object containing data of the loaded ad.
coverImagePath
coverImagePath
Declaration
Discussion
The path to the file of the cover image of the loaded ad if the loaded ad has video content.
- registerViewForInteraction:withViewController:
- registerViewForInteraction:withViewController:
Declaration
Parameters
name
description
view
A widget used to handle tap gesture for ad engagement.
viewController
The view controller containing the view
parameter.
Discussion
This method is used to register custom widget for ad engagement. SDK add a tag gesture recognizer to view
passed in to redirect user to langing page.
- registerViewForInteraction:withViewController:withClickableViews:
- registerViewForInteraction:withViewController:withClickableViews:
Declaration
Parameters
name
description
view
The container view for widgets.
viewController
The view controller containing the view
parameter.
clickableViews
Widgets to handle ad engagement.
Discussion
This method is used to register a series of custom widgets for ad engagement. SDK add tag gesture recognizers to clickableViews
passed in to redirect users to langing page.
- loadAdInstantWithInfo:
- loadAdInstantWithInfo:
Declaration
Parameters
name
description
info
CERequestInfo
instance used to specify the parameters for ad request.
error
NSError
instance used to specify the error for ad request.
Discussion
Start loading ad content process synchronously, and it will ignore the timeout in CERequestInfo.
- loadAdAsyncWithInfo:
- loadAdAsyncWithInfo:
Declaration
Parameters
name
description
info
CERequestInfo
instance used to specify the parameters for ad request.
reqDelegate
id<CENativeAdRequestDelegate> instance that receive request ad event.
Discussion
Start loading ad content process asynchronously.
[CENativeAdRequestDelegate nativeAdDidLoad:]
is invoked if an ad is ready before timeout; otherwise, [CENativeAdRequestDelegate nativeAd:didFailWithError:]
is invoked.
- hasVideoContent
- hasVideoContent
Declaration
Return Value
YES
if the loaded ad is a video ad; otherwise, NO
;
- getTotalFileSize
- getTotalFileSize
Declaration
Return Value
The total size of the creative files downloaded for this ad.
Last updated