MarketingCloudSDKInboxMessagesDelegate

Objective-C

@interface MarketingCloudSDKInboxMessagesDelegate : NSObject

Swift

class MarketingCloudSDKInboxMessagesDelegate : NSObject

The MarketingCloudSDKInboxMessagesDelegate is an interface object for Inbox support. It was designed to be used as a simple delegate for a UITableView, and can be allocated and used as such without too much other customization. It only supports tableView:didSelectRowAtIndexPath: to offer (along with the data source) a VERY simple inbox implementation.

  • Create an instance of a basic UITableView delegate to handle cell selection for a simple view controller showing Inbox messages.

    Declaration

    Objective-C

    - (id _Nullable)
        initWithMarketingCloudSDK:(MobilePushSDK *_Nonnull)sdk
                        tableView:(UITableView *_Nonnull)tableView
                       dataSource:
                           (MarketingCloudSDKInboxMessagesDataSource *_Nonnull)
                               dataSource;

    Swift

    init?(marketingCloudSDK sdk: MobilePushSDK, tableView: UITableView, dataSource: MarketingCloudSDKInboxMessagesDataSource)

    Parameters

    sdk

    An instance of MarketingCloudSDK.

    tableView

    The UITableView used in the view controller. The delegate will “own” selection of the cells.

    dataSource

    An instance of MarketingCloudSDKInboxMessagesDataSource, a class which implements a simple set of methods from the UITableViewDataSource protocol.

    Return Value

    An instance of MarketingCloudSDKInboxMessagesDelegate, a class which implements a simple set of methods from the UITableViewDelegate protocol.