XAAdvertisement Class Reference
| Inherits from | NSObject |
|---|---|
| Declared in | XAAdvertisement.h |
Overview
The XAAdvertisement is the main business object that contains all the necessary information
for ad playback.
Initialize an Advertisement
+ advertisementWith:
Create an advertisement from a dictionary of values
+ (XAAdvertisement *)advertisementWith:(NSDictionary *)dictionaryParameters
dictionary |
A dictionary of values |
|---|
Return Value
A new advertisement
Discussion
Create an advertisement from a dictionary of values
Declared In
XAAdvertisement.h
+ advertisementWithComponents:
Create an advertisement with the supplied ad components.
+ (XAAdvertisement *)advertisementWithComponents:(XAAdComponents *)componentsParameters
components |
An ad components object. |
|---|
Return Value
A new advertisement
Discussion
Create an advertisement with the supplied ad components.
Declared In
XAAdvertisement.h
+ advertisementWithTitle:category:impressionTracking:creative:
Create an advertisement with the required components for DAAST.
+ (XAAdvertisement *)advertisementWithTitle:(NSString *)title category:(NSString *)category impressionTracking:(NSArray *)impressionTracking creative:(NSArray *)creativesParameters
title |
The title for the advertisement. |
|---|---|
category |
The category of the advertisement. |
impressionTracking |
An array or URLs that are used for tracking if an impression was served. |
creatives |
An array of creatives for the advertisement. |
Return Value
A new advertisement
Discussion
Create an advertisement with the required components for DAAST.
Declared In
XAAdvertisement.h
+ advertisementWithTitle:category:impressionTracking:creative:settings:
Create an advertisement with the required components for DAAST as well as a settings object.
+ (XAAdvertisement *)advertisementWithTitle:(NSString *)title category:(NSString *)category impressionTracking:(NSArray *)impressionTracking creative:(NSArray *)creatives settings:(XASettings *)settingsParameters
title |
The title for the advertisement. |
|---|---|
category |
The category of the advertisement. |
impressionTracking |
An array of URLs that are used for tracking if an impression was served. |
creatives |
An array of creatives for the advertisement. |
settings |
A settings object for configuring playback. |
Return Value
A new advertisement
Discussion
Create an advertisement with the required components for DAAST as well as a settings object.
Declared In
XAAdvertisement.h
settings
Settings for the advertisement, used to customize items such as stall thresholds, loading timeouts, display preferences.
@property (nonatomic, retain, readonly) XASettings *settingsDiscussion
Settings for the advertisement, used to customize items such as stall thresholds, loading timeouts, display preferences.
Declared In
XAAdvertisement.h
Advertisement Data
requestKey
The request ID associated with the advertisement.
@property (nonatomic, retain, readonly) NSString *requestKeyDiscussion
The request ID associated with the advertisement.
Used within XAPP to tie off to the particular request.
Declared In
XAAdvertisement.h
sessionKey
The key associated with the session the advertisement was served within.
@property (nonatomic, retain, readonly) NSString *sessionKeyDiscussion
The key associated with the session the advertisement was served within.
Declared In
XAAdvertisement.h
nowPlayingText
Now Playing Text is used for lock screen controls and bluetooth devices
@property (nonatomic, retain, readonly) NSString *nowPlayingTextDiscussion
Now Playing Text is used for lock screen controls and bluetooth devices
Declared In
XAAdvertisement.h
userData
User data associated with the advertisement. Currently only used for phone calls where we call the user.
@property (nonatomic, retain) XAUserData *userDataDiscussion
User data associated with the advertisement. Currently only used for phone calls where we call the user.
Declared In
XAAdvertisement.h
DAAST Required
adID
The ID associated with the advertisement playback.
@property (nonatomic, retain, readonly) NSString *adIDDeclared In
XAAdvertisement.h
adTitle
The name of the advertisement
@property (nonatomic, retain, readonly) NSString *adTitleDeclared In
XAAdvertisement.h
impressionTracking
An array of URLs that are called when the ad has registered an impression.
@property (nonatomic, retain, readonly) NSArray *impressionTrackingDiscussion
An array of URLs that are called when the ad has registered an impression.
See ~!@DAAST 3.1.4.1 Required
Declared In
XAAdvertisement.h
linearCreative
The main linear creative for the ad.
@property (nonatomic, retain, readonly) XALinear *linearCreativeDeclared In
XAAdvertisement.h
creatives
An array of creative, either companion or linear creative.
@property (nonatomic, retain, readonly) NSArray *creativesDiscussion
An array of creative, either companion or linear creative.
See ~!@DAAST 3.1.4.1 Required
Declared In
XAAdvertisement.h
category
The category for the ad.
@property (nonatomic, retain, readonly) NSString *categoryDeclared In
XAAdvertisement.h
DAAST Optional
adSystem
The server that returned the advertisement.
@property (nonatomic, retain, readonly) NSString *adSystemDeclared In
XAAdvertisement.h
adDescription
A description for the ad.
@property (nonatomic, retain, readonly) NSString *adDescriptionDeclared In
XAAdvertisement.h
advertiser
The account for the advertisement
@property (nonatomic, retain, readonly) NSString *advertiserDeclared In
XAAdvertisement.h
complementaryCompanion
The companion for the advertisement that is displayed during playback.
@property (nonatomic, retain, readonly) NSObject<XACompanion,XAComplementaryCompanion> *complementaryCompanionDiscussion
The companion for the advertisement that is displayed during playback.
Declared In
XAAdvertisement.h
leaveBehindCompanion
The companion for the advertisement that is left behind after the ad finishes.
@property (nonatomic, retain, readonly) NSObject<XACompanion,XALeaveBehindCompanion> *leaveBehindCompanionDiscussion
The companion for the advertisement that is left behind after the ad finishes.
Declared In
XAAdvertisement.h
Advertisement Playback
– deviceCanPlay:
Check if the device has the necessary capabilities to play the ad properly.
- (BOOL)deviceCanPlay:(NSError **)errorParameters
error |
Reference to an error whereas if the ad cannot be played, the error will be initialized with the appropriate error |
|---|
Return Value
BOOL if the ad can be played on the current device
Discussion
Check if the device has the necessary capabilities to play the ad properly.
Declared In
XAAdvertisement.h