commit | author | age
|
96fe76
|
1 |
// |
L |
2 |
// GADNativeAdDelegate.h |
|
3 |
// Google Mobile Ads SDK |
|
4 |
// |
|
5 |
// Copyright 2017 Google LLC. All rights reserved. |
|
6 |
// |
|
7 |
|
|
8 |
#import <Foundation/Foundation.h> |
|
9 |
|
|
10 |
@class GADNativeAd; |
|
11 |
|
|
12 |
/// Identifies native ad assets. |
|
13 |
@protocol GADNativeAdDelegate <NSObject> |
|
14 |
|
|
15 |
@optional |
|
16 |
|
|
17 |
#pragma mark - Ad Lifecycle Events |
|
18 |
|
|
19 |
/// Called when an impression is recorded for an ad. |
|
20 |
- (void)nativeAdDidRecordImpression:(nonnull GADNativeAd *)nativeAd; |
|
21 |
|
|
22 |
/// Called when a click is recorded for an ad. |
|
23 |
- (void)nativeAdDidRecordClick:(nonnull GADNativeAd *)nativeAd; |
|
24 |
|
|
25 |
/// Called when a swipe gesture click is recorded for an ad. |
|
26 |
- (void)nativeAdDidRecordSwipeGestureClick:(nonnull GADNativeAd *)nativeAd; |
|
27 |
|
|
28 |
#pragma mark - Click-Time Lifecycle Notifications |
|
29 |
|
|
30 |
/// Called before presenting the user a full screen view in response to an ad action. Use this |
|
31 |
/// opportunity to stop animations, time sensitive interactions, etc. |
|
32 |
/// |
|
33 |
/// Normally the user looks at the ad, dismisses it, and control returns to your application with |
|
34 |
/// the nativeAdDidDismissScreen: message. However, if the user hits the Home button or clicks on an |
|
35 |
/// App Store link, your application will be backgrounded. The next method called will be the |
|
36 |
/// applicationWillResignActive: of your UIApplicationDelegate object. |
|
37 |
- (void)nativeAdWillPresentScreen:(nonnull GADNativeAd *)nativeAd; |
|
38 |
|
|
39 |
/// Called before dismissing a full screen view. |
|
40 |
- (void)nativeAdWillDismissScreen:(nonnull GADNativeAd *)nativeAd; |
|
41 |
|
|
42 |
/// Called after dismissing a full screen view. Use this opportunity to restart anything you may |
|
43 |
/// have stopped as part of nativeAdWillPresentScreen:. |
|
44 |
- (void)nativeAdDidDismissScreen:(nonnull GADNativeAd *)nativeAd; |
|
45 |
|
|
46 |
#pragma mark - Mute This Ad |
|
47 |
|
|
48 |
/// Used for Mute This Ad feature. Called after the native ad is muted. Only called for Google ads |
|
49 |
/// and is not supported for mediated ads. |
|
50 |
- (void)nativeAdIsMuted:(nonnull GADNativeAd *)nativeAd; |
|
51 |
|
|
52 |
@end |