iOS Interstitial Integration

In order to integrate the Interstitial ads, you need to use the Yodo1MasInterstitialAdDelegate delegate.

1. Set the Interstitial Ad Delegate Method

For Swift

Yodo1Mas.sharedInstance().interstitialAdDelegate = self

func onAdOpened(_ event: Yodo1MasAdEvent) {
           
}
    
func onAdClosed(_ event: Yodo1MasAdEvent) {
        
}
    
func onAdError(_ event: Yodo1MasAdEvent, _ error: Yodo1MasError) {

}

For Obejective C

[Yodo1Mas sharedInstance].interstitialAdDelegate = self;

#pragma mark - Interstitial Delegate
- (void)onAdOpened:(Yodo1MasAdEvent *)event {
    
}

- (void)onAdClosed:(Yodo1MasAdEvent *)event {
    
}

- (void)onAdError:(Yodo1MasAdEvent *)event error:(Yodo1MasError *)error {
    
}       


2. Check the Loading Status of Interstitials

For Swift

let isLoaded = Yodo1Mas.sharedInstance().isInterstitialAdLoaded()

For Objective C

BOOL isLoaded = [[Yodo1Mas sharedInstance] isInterstitialAdLoaded];


3. Show Interstitial Ad

For Swift

Yodo1Mas.sharedInstance().showInterstitialAd()

For Objective C

[[Yodo1Mas sharedInstance] showInterstitialAd];
Updated on July 21, 2021

Was this article helpful?

Related Articles