YMARewardedAdDelegate Protocol Reference

Conforms to NSObject
Declared in YMARewardedAd.h

Overview

The protocol defines the methods of the delegate that tracks ads. Methods are called by an object of the YMARewardedAd class when its state changes.

  1. Methods
    1. – rewardedAd:didReward:
    2. – rewardedAdDidLoadAd:
    3. – rewardedAdDidFailToLoadAd:error:
    4. – rewardedAdWillLeaveApplication:
    5. – rewardedAdDidFailToPresentAd:error:
    6. – rewardedAdWillAppear:
    7. – rewardedAdDidAppear:
    8. – rewardedAdWillDisappear:
    9. – rewardedAdDidDisappear:
    10. – rewardedAd:willPresentScreen:

Methods

– rewardedAd:didReward:

Notifies that the user should be rewarded for viewing an ad (impression counted).

- (void)rewardedAd:(YMARewardedAd *)rewardedAd
         didReward:(id<YMAReward>)reward

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

reward

The user’s reward (YMAReward).

– rewardedAdDidLoadAd:

Notifies that the ad has been loaded successfully.

- (void)rewardedAdDidLoadAd:(YMARewardedAd *)rewardedAd

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

– rewardedAdDidFailToLoadAd:error:

Notifies that the ad failed to load.

- (void)rewardedAdDidFailToLoadAd:(YMARewardedAd *)rewardedAd
                            error:(NSError *)error

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

error

Information about the error (for details, see YMAAdErrorCode).

– rewardedAdWillLeaveApplication:

Notifies that the app will run in the background now because the user clicked on the ad and is about to switch to a different app (Phone, App Store, and so on).

- (void)rewardedAdWillLeaveApplication:(YMARewardedAd *)rewardedAd

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

– rewardedAdDidFailToPresentAd:error:

Notifies that the ad can’t be displayed.

- (void)rewardedAdDidFailToPresentAd:(YMARewardedAd *)rewardedAd
                               error:(NSError *)error

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

error

Information about the error (for details, see YMAAdErrorCode).

– rewardedAdWillAppear:

Called before the rewarded ad appears.

- (void)rewardedAdWillAppear:(YMARewardedAd *)rewardedAd

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

– rewardedAdDidAppear:

Called after the rewarded ad appears.

- (void)rewardedAdDidAppear:(YMARewardedAd *)rewardedAd

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

– rewardedAdWillDisappear:

Called before hiding the rewarded ad.

- (void)rewardedAdWillDisappear:(YMARewardedAd *)rewardedAd

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

– rewardedAdDidDisappear:

Called after hiding the rewarded ad.

- (void)rewardedAdDidDisappear:(YMARewardedAd *)rewardedAd

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

– rewardedAd:willPresentScreen:

Notifies that the in-app browser will be displayed.

- (void)rewardedAd:(YMARewardedAd *)rewardedAd
 willPresentScreen:(UIViewController *)viewController

Parameters

rewardedAd

A reference to the object of the YMARewardedAd class that invoked the method.

viewController

Modal UIViewController (in-app browser).


Generated by appledoc 2.2.1 (build 1334).