16#import <Foundation/Foundation.h>
18NS_ASSUME_NONNULL_BEGIN
41@property(nonatomic, readonly, strong, nullable) NSString *
name;
56@property(nonatomic, readonly, strong, nullable) NSString *
bannerURL;
61@property(nonatomic, readonly, strong, nullable) NSString *
itemImageURL;
79@property(nonatomic, readonly)
int itemID;
89@property(nonatomic, readonly) BOOL
bUnlock;
104@property(nonatomic, readonly, strong, nullable) NSURL *
linkURL;
109@property(nonatomic, readonly, strong, nullable) NSString *
lisenceText;
114@property(nonatomic, readonly, strong, nullable) NSURL *
sampleURL;
127- (instancetype)initWithDictionary:(nullable NSDictionary *)dictionary;
148- (BOOL)checkExistPackList:(nullable NSArray *)packList packID:(
int)packID;
158- (void)replaceServerUnlock:(BOOL)serverUnlock;
178- (BOOL)hasItem:(
int)itemType itemID:(
int)itemID;
CampaignItemInfoItemType
The kind of item a campaign entry unlocks, as stored in itemType.
Definition CampaignItemInfo.h:23
@ CampaignItemInfoItemTypeMarker
A marker: only has to be installed.
Definition CampaignItemInfo.h:25
@ CampaignItemInfoItemTypeTune
A tune: must be in the catalogue and present on disc.
Definition CampaignItemInfo.h:24
A campaign item: an unlockable tune or marker with a rule for earning it.
Definition CampaignItemInfo.h:32
NSURL * sampleURL
A sample of the item.
Definition CampaignItemInfo.h:114
int buttonType
Which button the UI should offer.
Definition CampaignItemInfo.h:94
int campaignID
The campaign this item belongs to.
Definition CampaignItemInfo.h:36
NSString * itemDescription
What the item is.
Definition CampaignItemInfo.h:46
int hideType
How the UI should hide the item.
Definition CampaignItemInfo.h:99
NSString * bannerURL
The campaign banner's address.
Definition CampaignItemInfo.h:56
int itemID
Which tune or marker the item grants.
Definition CampaignItemInfo.h:79
NSString * name
The item's display name.
Definition CampaignItemInfo.h:41
int itemType
What kind of item this is.
Definition CampaignItemInfo.h:74
NSString * lisenceText
The item's licence text.
Definition CampaignItemInfo.h:109
NSString * itemImageURL
The item artwork's address.
Definition CampaignItemInfo.h:61
BOOL checkNewUnlock()
Whether the item is newly available: unlocked but not yet downloaded.
Definition CampaignItemInfo.m:226
NSURL * linkURL
Where the campaign's banner leads.
Definition CampaignItemInfo.h:104
BOOL termCheck()
Evaluates the unlock rule and sets every derived property from it.
Definition CampaignItemInfo.m:119
BOOL alreadyDownload
Whether the item's data is already on the device.
Definition CampaignItemInfo.h:84
NSString * unlockDescription
How to unlock it.
Definition CampaignItemInfo.h:51
BOOL bServerUnlock
Whether the server says this item is unlocked.
Definition CampaignItemInfo.h:69
BOOL bUnlock
Whether the unlock rule is satisfied.
Definition CampaignItemInfo.h:89