MAAdView Class Reference

Inherits from UIView
Declared in MAAdView.h

Overview

This class represents a view-based ad - i.e. banner, mrec or leader.

– initWithAdUnitIdentifier:

Create a new ad view for a given ad unit id.

- (instancetype)initWithAdUnitIdentifier:(NSString *)adUnitIdentifier

Parameters

adUnitIdentifier

Ad unit id to load ads for.

Discussion

Create a new ad view for a given ad unit id.

Declared In

MAAdView.h

– initWithAdUnitIdentifier:sdk:

Create a new ad view for a given ad unit id.

- (instancetype)initWithAdUnitIdentifier:(NSString *)adUnitIdentifier sdk:(ALSdk *)sdk

Parameters

adUnitIdentifier

Ad unit id to load ads for.

sdk

SDK to use. An instance of the SDK may be obtained by calling [ALSdk shared].

Discussion

Create a new ad view for a given ad unit id.

Declared In

MAAdView.h

– initWithAdUnitIdentifier:adFormat:

Create a new ad view for a given ad unit id and ad format.

- (instancetype)initWithAdUnitIdentifier:(NSString *)adUnitIdentifier adFormat:(MAAdFormat *)adFormat

Parameters

adUnitIdentifier

Ad unit id to load ads for.

adFormat

Ad format to load ads for.

Discussion

Create a new ad view for a given ad unit id and ad format.

Declared In

MAAdView.h

– initWithAdUnitIdentifier:adFormat:sdk:

Create a new ad view for a given ad unit id, ad format, and sdk.

- (instancetype)initWithAdUnitIdentifier:(NSString *)adUnitIdentifier adFormat:(MAAdFormat *)adFormat sdk:(ALSdk *)sdk

Parameters

adUnitIdentifier

Ad unit id to load ads for.

adFormat

Ad format to load ads for.

sdk

SDK to use. An instance of the SDK may be obtained by calling [ALSdk shared].

Discussion

Create a new ad view for a given ad unit id, ad format, and sdk.

Declared In

MAAdView.h

  delegate

Set a delegate that will be notified about ad events.

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

Discussion

Set a delegate that will be notified about ad events.

Declared In

MAAdView.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

MAAdView.h

– loadAd

Load ad for the current ad view. Use {@link MAAdView:delegate} to assign a delegate that should be notified about ad load state.

- (void)loadAd

Discussion

Load ad for the current ad view. Use {@link MAAdView:delegate} to assign a delegate that should be notified about ad load state.

Declared In

MAAdView.h

– startAutoRefresh

Starts or resumes auto-refreshing of the banner.

- (void)startAutoRefresh

Discussion

Starts or resumes auto-refreshing of the banner.

Declared In

MAAdView.h

– stopAutoRefresh

Pauses auto-refreshing of the banner.

- (void)stopAutoRefresh

Discussion

Pauses auto-refreshing of the banner.

Declared In

MAAdView.h

  placement

The placement to tie the future ad events to.

@property (nonatomic, copy, nullable) NSString *placement

Discussion

The placement to tie the future ad events to.

Declared In

MAAdView.h