| | |
| | | #import "BUDislikeWords.h" |
| | | #import "BUPlayerPublicDefine.h" |
| | | #import "BUMopubAdMarkUpDelegate.h" |
| | | #import "BUNativeExpressAdViewDelegate.h" |
| | | |
| | | NS_ASSUME_NONNULL_BEGIN |
| | | |
| | | @class BUNativeExpressAdManager; |
| | | |
| | | @protocol BUNativeExpressAdViewDelegate <NSObject> |
| | | |
| | | @optional |
| | | /** |
| | | * Sent when views successfully load ad |
| | | */ |
| | | - (void)nativeExpressAdSuccessToLoad:(BUNativeExpressAdManager *)nativeExpressAd views:(NSArray<__kindof BUNativeExpressAdView *> *)views; |
| | | |
| | | /** |
| | | * Sent when views fail to load ad |
| | | */ |
| | | - (void)nativeExpressAdFailToLoad:(BUNativeExpressAdManager *)nativeExpressAd error:(NSError *_Nullable)error; |
| | | |
| | | /** |
| | | * This method is called when rendering a nativeExpressAdView successed, and nativeExpressAdView.size.height has been updated |
| | | */ |
| | | - (void)nativeExpressAdViewRenderSuccess:(BUNativeExpressAdView *)nativeExpressAdView; |
| | | |
| | | /** |
| | | * This method is called when a nativeExpressAdView failed to render |
| | | */ |
| | | - (void)nativeExpressAdViewRenderFail:(BUNativeExpressAdView *)nativeExpressAdView error:(NSError *_Nullable)error; |
| | | |
| | | /** |
| | | * Sent when an ad view is about to present modal content |
| | | */ |
| | | - (void)nativeExpressAdViewWillShow:(BUNativeExpressAdView *)nativeExpressAdView; |
| | | |
| | | /** |
| | | * Sent when an ad view is clicked |
| | | */ |
| | | - (void)nativeExpressAdViewDidClick:(BUNativeExpressAdView *)nativeExpressAdView; |
| | | |
| | | /** |
| | | Sent when a playerw playback status changed. |
| | | @param playerState : player state after changed |
| | | */ |
| | | - (void)nativeExpressAdView:(BUNativeExpressAdView *)nativeExpressAdView stateDidChanged:(BUPlayerPlayState)playerState; |
| | | |
| | | /** |
| | | * Sent when a player finished |
| | | * @param error : error of player |
| | | */ |
| | | - (void)nativeExpressAdViewPlayerDidPlayFinish:(BUNativeExpressAdView *)nativeExpressAdView error:(NSError *)error; |
| | | |
| | | /** |
| | | * Sent when a user clicked dislike reasons. |
| | | * @param filterWords : the array of reasons why the user dislikes the ad |
| | | */ |
| | | - (void)nativeExpressAdView:(BUNativeExpressAdView *)nativeExpressAdView dislikeWithReason:(NSArray<BUDislikeWords *> *)filterWords; |
| | | |
| | | /** |
| | | * Sent after an ad view is clicked, a ad landscape view will present modal content |
| | | */ |
| | | - (void)nativeExpressAdViewWillPresentScreen:(BUNativeExpressAdView *)nativeExpressAdView; |
| | | |
| | | /** |
| | | This method is called when another controller has been closed. |
| | | @param interactionType : open appstore in app or open the webpage or view video ad details page. |
| | | */ |
| | | - (void)nativeExpressAdViewDidCloseOtherController:(BUNativeExpressAdView *)nativeExpressAdView interactionType:(BUInteractionType)interactionType; |
| | | |
| | | @end |
| | | |
| | | |
| | | @interface BUNativeExpressAdManager : NSObject <BUMopubAdMarkUpDelegate> |
| | |
| | | /** |
| | | The number of ads requested,The maximum is 3 |
| | | */ |
| | | - (void)loadAd:(NSInteger)count; |
| | | - (void)loadAdDataWithCount:(NSInteger)count; |
| | | @end |
| | | |
| | | @interface BUNativeExpressAdManager (Deprecated) |
| | | - (void)loadAd:(NSInteger)count __attribute__((deprecated("Use loadAdDataWithCount: instead."))); |
| | | @end |
| | | |
| | | |
| | | NS_ASSUME_NONNULL_END |