GADCustomEventInterstitialDelegate.h 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. //
  2. // GADCustomEventInterstitialDelegate.h
  3. // Google Mobile Ads SDK
  4. //
  5. // Copyright 2012 Google Inc. All rights reserved.
  6. //
  7. #import <Foundation/Foundation.h>
  8. #import "GoogleMobileAdsDefines.h"
  9. @protocol GADCustomEventInterstitial;
  10. /// Call back to this delegate in your custom event. You must call
  11. /// customEventInterstitial:didReceiveAd: when there is an ad to show, or
  12. /// customEventInterstitial:didFailAd: when there is no ad to show. Otherwise, if enough time passed
  13. /// (several seconds) after the SDK called the requestInterstitialAdWithParameter: method of your
  14. /// custom event, the mediation SDK will consider the request timed out, and move on to the next ad
  15. /// network.
  16. @protocol GADCustomEventInterstitialDelegate<NSObject>
  17. /// Your Custom Event object must call this when it receives or creates an interstitial ad.
  18. - (void)customEventInterstitialDidReceiveAd:(id<GADCustomEventInterstitial>)customEvent;
  19. /// Your Custom Event object must call this when it fails to receive or create the ad. Pass along
  20. /// any error object sent from the ad network's SDK, or an NSError describing the error. Pass nil if
  21. /// not available.
  22. - (void)customEventInterstitial:(id<GADCustomEventInterstitial>)customEvent
  23. didFailAd:(NSError *)error;
  24. /// Your Custom Event object should call this when the user touches or "clicks" the ad to initiate
  25. /// an action. When the SDK receives this callback, it reports the click back to the mediation
  26. /// server.
  27. - (void)customEventInterstitialWasClicked:(id<GADCustomEventInterstitial>)customEvent;
  28. /// When you call any of the the following methods, the call will be propagated back to the
  29. /// GADInterstitialDelegate that you implemented and passed to GADInterstitial.
  30. /// Your Custom Event should call this when the interstitial is being displayed.
  31. - (void)customEventInterstitialWillPresent:(id<GADCustomEventInterstitial>)customEvent;
  32. /// Your Custom Event should call this when the interstitial is about to be dismissed.
  33. - (void)customEventInterstitialWillDismiss:(id<GADCustomEventInterstitial>)customEvent;
  34. /// Your Custom Event should call this when the interstitial has been dismissed.
  35. - (void)customEventInterstitialDidDismiss:(id<GADCustomEventInterstitial>)customEvent;
  36. /// Your Custom Event should call this method when a user action will result in app switching.
  37. - (void)customEventInterstitialWillLeaveApplication:(id<GADCustomEventInterstitial>)customEvent;
  38. #pragma mark Deprecated
  39. - (void)customEventInterstitial:(id<GADCustomEventInterstitial>)customEvent
  40. didReceiveAd:(NSObject *)ad
  41. GAD_DEPRECATED_MSG_ATTRIBUTE("Use customEventInterstitialDidReceiveAd:.");
  42. @end