GoogleMobileAds Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
GADNativeAdDelegate
@protocol GADNativeAdDelegate <NSObject>
Identifies native ad assets.
-
Called when an impression is recorded for an ad.
Declaration
Swift
optional func nativeAdDidRecordImpression(_ nativeAd:
GADNativeAd
)
Objective-C
- (void)nativeAdDidRecordImpression:(nonnull
GADNativeAd
*)nativeAd;
-
Called when a click is recorded for an ad.
Declaration
Swift
optional func nativeAdDidRecordClick(_ nativeAd:
GADNativeAd
)
Objective-C
- (void)nativeAdDidRecordClick:(nonnull
GADNativeAd
*)nativeAd;
-
Called when a swipe gesture click is recorded for an ad.
Declaration
Swift
optional func nativeAdDidRecordSwipeGestureClick(_ nativeAd:
GADNativeAd
)
Objective-C
- (void)nativeAdDidRecordSwipeGestureClick:(nonnull
GADNativeAd
*)nativeAd;
-
Called before presenting the user a full screen view in response to an ad action. Use this
opportunity to stop animations, time sensitive interactions, etc.
Normally the user looks at the ad, dismisses it, and control returns to your application with
the nativeAdDidDismissScreen: message. However, if the user hits the Home button or clicks on an
App Store link, your application will be backgrounded. The next method called will be the
applicationWillResignActive: of your UIApplicationDelegate object.
Declaration
Swift
optional func nativeAdWillPresentScreen(_ nativeAd:
GADNativeAd
)
Objective-C
- (void)nativeAdWillPresentScreen:(nonnull
GADNativeAd
*)nativeAd;
-
Called before dismissing a full screen view.
Declaration
Swift
optional func nativeAdWillDismissScreen(_ nativeAd:
GADNativeAd
)
Objective-C
- (void)nativeAdWillDismissScreen:(nonnull
GADNativeAd
*)nativeAd;
-
Called after dismissing a full screen view. Use this opportunity to restart anything you may
have stopped as part of nativeAdWillPresentScreen:.
Declaration
Swift
optional func nativeAdDidDismissScreen(_ nativeAd:
GADNativeAd
)
Objective-C
- (void)nativeAdDidDismissScreen:(nonnull
GADNativeAd
*)nativeAd;
-
Used for Mute This Ad feature. Called after the native ad is muted. Only called for Google ads
and is not supported for mediated ads.
Declaration
Swift
optional func nativeAdIsMuted(_ nativeAd:
GADNativeAd
)
Objective-C
- (void)nativeAdIsMuted:(nonnull
GADNativeAd
*)nativeAd;
Except as otherwise noted, the content of this page is licensed under the
Creative Commons Attribution 4.0 License
, and code samples are licensed under the
Apache 2.0 License
. For details, see the
Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2022-10-30 UTC.
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"Missing the information I need"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"Too complicated / too many steps"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"Out of date"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"Samples / code issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]