MAAppOpenAdapterDelegate.h 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. //
  2. // MAAppOpenAdapterDelegate.h
  3. // AppLovinSDK
  4. //
  5. // Created by Andrew Tian on 7/26/22.
  6. //
  7. #import <AppLovinSDK/MAAdapterDelegate.h>
  8. @class MAAdapterError;
  9. NS_ASSUME_NONNULL_BEGIN
  10. /**
  11. * Protocol for adapters to forward ad load and display events to the MAX SDK for app open ads.
  12. */
  13. @protocol MAAppOpenAdapterDelegate <MAAdapterDelegate>
  14. /**
  15. * This method should called when an ad has been loaded.
  16. */
  17. - (void)didLoadAppOpenAd;
  18. /**
  19. * This method should called when an ad has been loaded.
  20. *
  21. * @param extraInfo Extra info passed from the adapter.
  22. */
  23. - (void)didLoadAppOpenAdWithExtraInfo:(nullable NSDictionary<NSString *, id> *)extraInfo;
  24. /**
  25. * This method should be called when an ad could not be loaded.
  26. *
  27. * @param adapterError An error object that indicates the cause of ad failure.
  28. */
  29. - (void)didFailToLoadAppOpenAdWithError:(MAAdapterError *)adapterError;
  30. /**
  31. * This method should be called when the adapter has successfully displayed an ad to the user.
  32. */
  33. - (void)didDisplayAppOpenAd;
  34. /**
  35. * This method should be called when the adapter has successfully displayed an ad to the user.
  36. *
  37. * @param extraInfo Extra info passed from the adapter.
  38. */
  39. - (void)didDisplayAppOpenAdWithExtraInfo:(nullable NSDictionary<NSString *, id> *)extraInfo;
  40. /**
  41. * This method should be called when the user has clicked adapter's ad.
  42. */
  43. - (void)didClickAppOpenAd;
  44. /**
  45. * This method should be called when the user has clicked adapter's ad.
  46. *
  47. * @param extraInfo Extra info passed from the adapter.
  48. */
  49. - (void)didClickAppOpenAdWithExtraInfo:(nullable NSDictionary<NSString *, id> *)extraInfo;
  50. /**
  51. * This method should be called when adapter's ad has been dismissed.
  52. */
  53. - (void)didHideAppOpenAd;
  54. /**
  55. * This method should be called when adapter's ad has been dismissed.
  56. *
  57. * @param extraInfo Extra info passed from the adapter.
  58. */
  59. - (void)didHideAppOpenAdWithExtraInfo:(nullable NSDictionary<NSString *, id> *)extraInfo;
  60. /**
  61. * This method should be called when an ad could not be displayed.
  62. *
  63. * @param adapterError An error object that indicates the cause of the failure.
  64. */
  65. - (void)didFailToDisplayAppOpenAdWithError:(MAAdapterError *)adapterError;
  66. /**
  67. * This method should be called when an ad could not be displayed.
  68. *
  69. * @param adapterError An error object that indicates the cause of the failure.
  70. * @param extraInfo Extra info passed from the adapter.
  71. */
  72. - (void)didFailToDisplayAppOpenAdWithError:(MAAdapterError *)adapterError extraInfo:(nullable NSDictionary<NSString *, id> *)extraInfo;
  73. @end
  74. NS_ASSUME_NONNULL_END