public interface

InboxMessageManager

com.salesforce.marketingcloud.messages.inbox.InboxMessageManager

Summary

Nested Classes
interface InboxMessageManager.InboxRefreshListener  
interface InboxMessageManager.InboxResponseListener  
Public Methods
abstract void deleteMessage(InboxMessage message)
Marks a InboxMessage as deleted in local storage.
abstract int getDeletedMessageCount()
Get the number deleted Inbox Messages regardless of their read status.
abstract List<InboxMessage> getDeletedMessages()
Gets a List of Active, Deleted Inboc Messages for use with your own adapter.
abstract int getMessageCount()
abstract List<InboxMessage> getMessages()
Gets a List of Active, Read & Unread, not Deleted Inbox Messages for use with your own adapter.
abstract int getReadMessageCount()
Get the number of read, not deleted Inbox Messages
abstract List<InboxMessage> getReadMessages()
Gets a List of Active, Read, not Deleted Inbox Messages for use with your own adapter.
abstract int getUnreadMessageCount()
Get the number of unread, not deleted Inbox Messages
abstract List<InboxMessage> getUnreadMessages()
Gets a List of Active, Unread, not Deleted Inbox Messages for use with your own adapter.
abstract void markAllMessagesDeleted()
Marks all active InboxMessages as deleted.
abstract void markAllMessagesRead()
Marks all active, unread InboxMessages as read.
abstract void refreshInbox(InboxMessageManager.InboxRefreshListener listener)
Requests an updated list of Inbox Messages from the Marketing Cloud Servers.
abstract void registerInboxResponseListener(InboxMessageManager.InboxResponseListener listener)
Call this method to be notified of Inbox events within the Marketing Cloud SDK.
abstract void setMessageRead(InboxMessage message)
Marks a InboxMessage as read in local storage.
abstract void unregisterInboxResponseListener(InboxMessageManager.InboxResponseListener listener)

Public Methods

public abstract void deleteMessage (InboxMessage message)

Marks a InboxMessage as deleted in local storage. This will prevent the message from being shown in the future unless local storage is cleared on the device.

Parameters
message is the InboxMessage to mark as deleted.

public abstract int getDeletedMessageCount ()

Get the number deleted Inbox Messages regardless of their read status.

Returns
  • int representation of the total number of messages

public abstract List<InboxMessage> getDeletedMessages ()

Gets a List of Active, Deleted Inboc Messages for use with your own adapter.

A Inbox Message is considered Active if its startDateUtc() is in the past and its endDateUtc() is NULL or in the future.

Returns

public abstract int getMessageCount ()

Returns
  • int representation of the total number of messages Get the total number of not deleted Inbox Messages regardless of their read status.

public abstract List<InboxMessage> getMessages ()

Gets a List of Active, Read & Unread, not Deleted Inbox Messages for use with your own adapter.

A Inbox Message is considered Active if its startDateUtc() is in the past and its endDateUtc() is NULL or in the future.

Returns

public abstract int getReadMessageCount ()

Get the number of read, not deleted Inbox Messages

Returns
  • int representation of the number of read messages

public abstract List<InboxMessage> getReadMessages ()

Gets a List of Active, Read, not Deleted Inbox Messages for use with your own adapter.

A Inbox Message is considered Active if its startDateUtc() is in the past and its endDateUtc() is NULL or in the future.

Returns

public abstract int getUnreadMessageCount ()

Get the number of unread, not deleted Inbox Messages

Returns
  • int representation of the number of unread messages

public abstract List<InboxMessage> getUnreadMessages ()

Gets a List of Active, Unread, not Deleted Inbox Messages for use with your own adapter.

A Inbox Message is considered Active if its startDateUtc() is in the past and its endDateUtc() is NULL or in the future.

Returns

public abstract void markAllMessagesDeleted ()

Marks all active InboxMessages as deleted.

public abstract void markAllMessagesRead ()

Marks all active, unread InboxMessages as read.

public abstract void refreshInbox (InboxMessageManager.InboxRefreshListener listener)

Requests an updated list of Inbox Messages from the Marketing Cloud Servers. The Inbox request can be made, at most, once per minute. This throttle also includes the Inbox request that is made by the SDK when your application is brought into the foreground.

Parameters
listener Provide an instance of an InboxMessageManager.InboxRefreshListener to be notified of the completion of the refresh. This listener is only guaranteed to be called for this single request and as long as the application remains in the foreground. If the application is backgrounded while the refresh request is in flight then the listener instance may become invalid due to restrictions imposed by Android, and thus cannot be notified upon completion.

public abstract void registerInboxResponseListener (InboxMessageManager.InboxResponseListener listener)

Call this method to be notified of Inbox events within the Marketing Cloud SDK.

Parameters
listener the class that implements InboxMessageManager.InboxResponseListener. Null values for this parameter are ignored.

public abstract void setMessageRead (InboxMessage message)

Marks a InboxMessage as read in local storage. This status will persist unless local storage is cleared on the device.

Parameters
message is the InboxMessage to mark as read.

public abstract void unregisterInboxResponseListener (InboxMessageManager.InboxResponseListener listener)

Parameters
listener the class that implements InboxMessageManager.InboxResponseListener.