MARewardedAd Class Reference

Inherits from NSObject
Declared in MARewardedAd.h

Overview

This class represents a full screen rewarded ad.

+ sharedWithAdUnitIdentifier:

Get an instance of rewarded ad.

+ (instancetype)sharedWithAdUnitIdentifier:(NSString *)adUnitIdentifier

Parameters

adUnitIdentifier

Ad unit id for which to get the instance.

Return Value

An instance of rewarded ad tied to the specified ad unit ID.

Discussion

Get an instance of rewarded ad.

Declared In

MARewardedAd.h

+ sharedWithAdUnitIdentifier:sdk:

Get an instance of rewarded ad.

+ (instancetype)sharedWithAdUnitIdentifier:(NSString *)adUnitIdentifier sdk:(ALSdk *)sdk

Parameters

adUnitIdentifier

Ad unit id for which to get the instance.

sdk

SDK to use.

Return Value

An instance of rewarded ad tied to the specified ad unit ID.

Discussion

Get an instance of rewarded ad.

Declared In

MARewardedAd.h

  delegate

Set a delegate that will be notified about ad events.

@property (nonatomic, weak, nullable) id<MARewardedAdDelegate> delegate

Discussion

Set a delegate that will be notified about ad events.

Declared In

MARewardedAd.h

– setExtraParameterForKey:value:

Set an extra parameter for the ad.

- (void)setExtraParameterForKey:(NSString *)key value:(nullable NSString *)value

Parameters

key

Parameter key.

value

Parameter value.

Discussion

Set an extra parameter for the ad.

Declared In

MARewardedAd.h

– loadAd

Load ad for the current rewarded ad. Use [MARewardedAd delegate] to assign a delegate that should be notified about ad load state.

- (void)loadAd

Discussion

Load ad for the current rewarded ad. Use [MARewardedAd delegate] to assign a delegate that should be notified about ad load state.

Declared In

MARewardedAd.h

– showAd

Show the loaded rewarded ad.

- (void)showAd

Discussion

Show the loaded rewarded ad.

Use [MARewardedAd delegate] to assign a delegate that should be notified about display events. Use [MARewardedAd isReady] to check if an ad was successfully loaded.

Declared In

MARewardedAd.h

– showAdForPlacement:

Show the loaded rewarded ad for a given placement to tie ad events to.

- (void)showAdForPlacement:(nullable NSString *)placement

Parameters

placement

The placement to tie the showing ad’s events to.

Discussion

Show the loaded rewarded ad for a given placement to tie ad events to.

Use [MARewardedAd delegate] to assign a delegate that should be notified about display events. Use [MARewardedAd isReady] to check if an ad was successfully loaded.

Declared In

MARewardedAd.h

  ready

Check if this ad is ready to be shown.

@property (nonatomic, assign, readonly, getter=isReady) BOOL ready

Discussion

Check if this ad is ready to be shown.

Declared In

MARewardedAd.h