GoogleMobileAds Framework Reference

GADNativeAppInstallAd

class GADNativeAppInstallAd : GADNativeAd

Native app install ad. To request this ad type, you need to pass kGADAdLoaderAdTypeNativeAppInstall (see GADAdLoaderAdTypes.h) to the |adTypes| parameter in GADAdLoader’s initializer method. If you request this ad type, your delegate must conform to the GADNativeAppInstallAdLoaderDelegate protocol.

  • App title.

    Declaration

    Swift

    var headline: String? { get }
  • Text that encourages user to take some action with the ad. For example Install.

    Declaration

    Swift

    var callToAction: String? { get }
  • Application icon.

    Declaration

    Swift

    var icon: GADNativeAdImage? { get }
  • App description.

    Declaration

    Swift

    var body: String? { get }
  • The app store name. For example, App Store.

    Declaration

    Swift

    var store: String? { get }
  • String representation of the app’s price.

    Declaration

    Swift

    var price: String? { get }
  • Array of GADNativeAdImage objects related to the advertised application.

    Declaration

    Swift

    var images: [GADNativeAdImage]? { get }
  • App store rating (0 to 5).

    Declaration

    Swift

    @NSCopying var starRating: NSDecimalNumber? { get }
  • Video controller for controlling video playback in GADNativeAppInstallAdView’s mediaView.

    Declaration

    Swift

    var videoController: GADVideoController { get }
  • Registers ad view and asset views with this native ad.

    Declaration

    Swift

    func register(_ adView: UIView, assetViews: [GADNativeAppInstallAssetID : UIView])

    Parameters

    assetViews

    Dictionary of asset views keyed by asset IDs.

  • Registers ad view, clickable asset views, and nonclickable asset views with this native ad. Media view shouldn’t be registered as clickable.

    Declaration

    Swift

    func register(_ adView: UIView, clickableAssetViews: [GADNativeAppInstallAssetID : UIView], nonclickableAssetViews: [GADNativeAppInstallAssetID : UIView])

    Parameters

    clickableAssetViews

    Dictionary of asset views that are clickable, keyed by asset IDs.

    nonclickableAssetViews

    Dictionary of asset views that are not clickable, keyed by asset IDs.

  • Unregisters ad view from this native ad. The corresponding asset views will also be unregistered.

    Declaration

    Swift

    func unregisterAdView()