MRCampaignManagerDelegate Protocol Reference
Conforms to | NSObject |
---|---|
Declared in | MRCampaignManager.h |
Overview
(Deprecated) Campaign is deprecated since version 7.4.0. It has been replaced by Triggers.
Delegate methods for MRCampaignManager
.
– campaignManager:shouldGenerateNotificationForCampaign:
Invoked when a campaign is triggered and a user notification will be generated.
- (BOOL)campaignManager:(MRCampaignManager *)manager shouldGenerateNotificationForCampaign:(NSDictionary *)campaignInfo
Parameters
manager |
The campaign manager object that will generate the notification. |
---|---|
campaignInfo |
A dictionary containing the details of the notification that will be sent.
Possible keys include: |
Return Value
Should return YES
if a notification should be generated and NO
if not.
Declared In
MRCampaignManager.h
– campaignManager:userInfoForCampaign:
Asks the delegate for data to include when triggering a campaign.
- (NSDictionary *)campaignManager:(MRCampaignManager *)manager userInfoForCampaign:(NSString *)campaignIdentifier
Parameters
manager |
The campaign manager asking for the data. |
---|---|
campaignIdentifier |
A string identifying the triggered campaign. |
Return Value
A dictionary of values to send to the third-party URL.
Discussion
When a campaign is triggered, the campaign manager will call this method before sending the request.
If you return a dictionary of parameters to include in the request, they will be forwarded to any
third-party URL associated with the campaign.
All parameter keys and values must be NSString
instances.
Declared In
MRCampaignManager.h
– campaignManager:didFailWithError:
Invoked when a campaign manager encounters an error.
- (void)campaignManager:(MRCampaignManager *)manager didFailWithError:(NSError *)error
Parameters
manager |
The campaign manager instance that’s reporting an error. |
---|---|
error |
The error being reported. |
Declared In
MRCampaignManager.h