commit | author | age
|
96fe76
|
1 |
// |
L |
2 |
// GADCustomEventBannerDelegate.h |
|
3 |
// Google Mobile Ads SDK |
|
4 |
// |
|
5 |
// Copyright 2012 Google LLC. All rights reserved. |
|
6 |
// |
|
7 |
|
|
8 |
#import <Foundation/Foundation.h> |
|
9 |
#import <UIKit/UIKit.h> |
|
10 |
|
|
11 |
#import <GoogleMobileAds/GoogleMobileAdsDefines.h> |
|
12 |
|
|
13 |
@protocol GADCustomEventBanner; |
|
14 |
|
|
15 |
/// Call back to this delegate in your custom event. You must call customEventBanner:didReceiveAd: |
|
16 |
/// when there is an ad to show, or customEventBanner:didFailAd: when there is no ad to show. |
|
17 |
/// Otherwise, if enough time passed (several seconds) after the SDK called the requestBannerAd: |
|
18 |
/// method of your custom event, the mediation SDK will consider the request timed out, and move on |
|
19 |
/// to the next ad network. |
|
20 |
GAD_DEPRECATED_MSG_ATTRIBUTE("Use GADMediationBannerAdEventDelegate instead.") |
|
21 |
@protocol GADCustomEventBannerDelegate <NSObject> |
|
22 |
|
|
23 |
/// Your Custom Event object must call this when it receives or creates an ad view. |
|
24 |
- (void)customEventBanner:(nonnull id<GADCustomEventBanner>)customEvent |
|
25 |
didReceiveAd:(nonnull UIView *)view; |
|
26 |
|
|
27 |
/// Your Custom Event object must call this when it fails to receive or create the ad view. Pass |
|
28 |
/// along any error object sent from the ad network's SDK, or an NSError describing the error. Pass |
|
29 |
/// nil if not available. |
|
30 |
- (void)customEventBanner:(nonnull id<GADCustomEventBanner>)customEvent |
|
31 |
didFailAd:(nullable NSError *)error; |
|
32 |
|
|
33 |
/// Your Custom Event object should call this when the user touches or "clicks" the ad to initiate |
|
34 |
/// an action. When the SDK receives this callback, it reports the click back to the mediation |
|
35 |
/// server. |
|
36 |
- (void)customEventBannerWasClicked:(nonnull id<GADCustomEventBanner>)customEvent; |
|
37 |
|
|
38 |
/// The rootViewController that you set in GADBannerView. Use this UIViewController to show a modal |
|
39 |
/// view when a user taps on the ad. |
|
40 |
@property(nonatomic, readonly, nonnull) UIViewController *viewControllerForPresentingModalView; |
|
41 |
|
|
42 |
/// When you call the following methods, the call will be propagated back to the |
|
43 |
/// GADBannerViewDelegate that you implemented and passed to GADBannerView. |
|
44 |
|
|
45 |
/// Your Custom Event should call this when the user taps an ad and a modal view appears. |
|
46 |
- (void)customEventBannerWillPresentModal:(nonnull id<GADCustomEventBanner>)customEvent; |
|
47 |
|
|
48 |
/// Your Custom Event should call this when the user dismisses the modal view and the modal view is |
|
49 |
/// about to go away. |
|
50 |
- (void)customEventBannerWillDismissModal:(nonnull id<GADCustomEventBanner>)customEvent; |
|
51 |
|
|
52 |
/// Your Custom Event should call this when the user dismisses the modal view and the modal view has |
|
53 |
/// gone away. |
|
54 |
- (void)customEventBannerDidDismissModal:(nonnull id<GADCustomEventBanner>)customEvent; |
|
55 |
|
|
56 |
#pragma mark Deprecated |
|
57 |
|
|
58 |
/// Deprecated. Use customEventBannerWasClicked:. |
|
59 |
- (void)customEventBanner:(nonnull id<GADCustomEventBanner>)customEvent |
|
60 |
clickDidOccurInAd:(nonnull UIView *)view |
|
61 |
GAD_DEPRECATED_MSG_ATTRIBUTE("Use customEventBannerWasClicked:."); |
|
62 |
|
|
63 |
/// Deprecated. No replacement. |
|
64 |
- (void)customEventBannerWillLeaveApplication:(nonnull id<GADCustomEventBanner>)customEvent |
|
65 |
GAD_DEPRECATED_MSG_ATTRIBUTE("Deprecated. No replacement."); |
|
66 |
|
|
67 |
@end |