public interface

CachePolicyDelegate

com.urbanairship.iam.assets.CachePolicyDelegate

Class Overview

Delegate used to determine the caching for a InAppMessage.

Summary

Public Methods
abstract boolean shouldCacheOnSchedule(String scheduleId, InAppMessage message)
Called to determine if the assets for a message should be cached on schedule.
abstract boolean shouldPersistCacheAfterDisplay(String scheduleId, InAppMessage message)
Called to determine if the cache should be cleared for an in-app message after the message is finished displaying.

Public Methods

public abstract boolean shouldCacheOnSchedule (String scheduleId, InAppMessage message)

Called to determine if the assets for a message should be cached on schedule.

Parameters
scheduleId The schedule Id.
message The in-app message.
Returns
  • true to cache, otherwise false.

public abstract boolean shouldPersistCacheAfterDisplay (String scheduleId, InAppMessage message)

Called to determine if the cache should be cleared for an in-app message after the message is finished displaying. The cache is always cleared if the schedule is cancelled, has reached its executing limit, or expires.

Parameters
scheduleId The schedule Id.
message The in-app message.
Returns
  • true to clear the cache, otherwise false.