插屏广告接入代码
1. 包含头文件 AdHubSDK.h
2. AdHubInterstitial 的创建和初始化
self.interstitial = [[AdHubInterstitial alloc] initWithSpaceID:[DemoIDData sharedInstance].interstitialSpaceID spaceParam:[DemoIDData sharedInstance].interstitialSpaceParam];
self.interstitial.delegate = self;
[self.interstitial loadAd];
3. AdHubInterstitial 主要属性说明
@property(nonatomic, readonly, copy) NSString *spaceID;
@property(nonatomic, readonly, copy) NSString *spaceParam;
@property(nonatomic,assign)BOOL needAnimation;
@property(nonatomic, weak) id<AdHubInterstitialDelegate> delegate;
4. AdHubInterstitial 展现方法
- (void)presentFromRootViewController:(UIViewController *)rootViewController;
5. AdHubInterstitialDelegate 的方法说明
@optional
- (void)interstitialDidReceiveAd:(AdHubInterstitial *)ad;
- (void)interstitial:(AdHubInterstitial *)ad didFailToReceiveAdWithError:(AdHubRequestError *)error;
- (void)interstitialDidPresentScreen:(AdHubInterstitial *)ad;
- (void)interstitialDidClick:(NSString *)landingPageURL;
- (void)interstitialDidDismissScreen:(AdHubInterstitial *)ad;