SASNativeAdAssets

Objective-C

@interface SASNativeAdAssets : NSObject

Swift

class SASNativeAdAssets : NSObject

Object representing all the assets that will be rendered in a given native ad.

  • The title if available, nil otherwise.

    Declaration

    Objective-C

    @property (readonly, nullable) NSString *title;

    Swift

    var title: String? { get }
  • The body if available, nil otherwise.

    Declaration

    Objective-C

    @property (readonly, nullable) NSString *body;

    Swift

    var body: String? { get }
  • The ‘call to action’ text if available, nil otherwise.

    Declaration

    Objective-C

    @property (readonly, nullable) NSString *callToAction;

    Swift

    var callToAction: String? { get }
  • The advertiser name if available, nil otherwise.

    Declaration

    Objective-C

    @property (readonly, nullable) NSString *advertiser;

    Swift

    var advertiser: String? { get }
  • The rating associated to the adverised product if available, nil otherwise.

    Declaration

    Objective-C

    @property (readonly, nullable) NSNumber *rating;

    Swift

    var rating: NSNumber? { get }
  • The asset representing the icon of the ad if available, nil otherwise.

    Declaration

    Objective-C

    @property (readonly, nullable) SASViewAsset *iconImage;

    Swift

    var iconImage: SASViewAsset? { get }
  • The view asset representing the main view of the ad (typically a cover image or a media) if available, nil otherwise.

    Declaration

    Objective-C

    @property (readonly, nullable) SASViewAsset *mainView;

    Swift

    var mainView: SASViewAsset? { get }
  • Initialize a new instance of SASNativeAdAssets.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithTitle:(nullable NSString *)title
                                     body:(nullable NSString *)body
                             callToAction:(nullable NSString *)callToAction
                               advertiser:(nullable NSString *)advertiser
                                   rating:(nullable NSNumber *)rating
                                iconImage:(nullable SASViewAsset *)iconImage
                                 mainView:(nullable SASViewAsset *)mainView;

    Swift

    init(title: String?, body: String?, callToAction: String?, advertiser: String?, rating: NSNumber?, iconImage: SASViewAsset?, mainView: SASViewAsset?)

    Parameters

    title

    The title if available, nil otherwise.

    body

    The body if available, nil otherwise.

    callToAction

    The ‘call to action’ text if available, nil otherwise.

    advertiser

    The advertiser name if available, nil otherwise.

    rating

    The rating associated to the adverised product if available, nil otherwise.

    iconImage

    The asset representing the icon of the ad if available, nil otherwise.

    mainView

    The view asset representing the main view of the ad if available, nil otherwise.

    Return Value

    An initialized instance of SASNativeAdAssets.