-
public interface ViewTrackerInterface that defines a Local Campaign view tracker.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classViewTracker.CountedViewEvent
-
Method Summary
Modifier and Type Method Description abstract ViewTracker.CountedViewEventtrackViewEvent(@NonNull() String campaignID, @Nullable() String customUserId)Track a view abstract ViewTracker.CountedViewEventgetViewEventByCampaignId(@NonNull() String campaignId)Get the counted view events for a given campaign ID abstract ViewTracker.CountedViewEventgetViewEventByCampaignIdAndCustomId(@NonNull() String campaignId, @Nullable() String customUserId)Get the counted view events for a given campaign ID and custom user ID abstract Map<String, Integer>getViewCountsByCampaignIds(@NonNull() List<String> campaignsIds)Tell how many times have campaigns been seen abstract Map<String, Integer>getViewCountsByCampaignIdsAndCustomUserId(@NonNull() List<String> campaignsIds, @Nullable() String customUserId)Tell how many times have campaigns been seen for a given custom user id abstract longgetCampaignLastOccurrence(@NonNull() String campaignId)Track how much time has passed since the last view of a campaign abstract intgetNumberOfViewEventsSince(long timestamp)Get the number of view event tracked since a given timestamp -
-
Method Detail
-
trackViewEvent
abstract ViewTracker.CountedViewEvent trackViewEvent(@NonNull() String campaignID, @Nullable() String customUserId)
Track a view
- Parameters:
campaignID- The campaign idcustomUserId- The custom user id
-
getViewEventByCampaignId
@NonNull() abstract ViewTracker.CountedViewEvent getViewEventByCampaignId(@NonNull() String campaignId)
Get the counted view events for a given campaign ID
- Parameters:
campaignId- The campaign id
-
getViewEventByCampaignIdAndCustomId
@NonNull() abstract ViewTracker.CountedViewEvent getViewEventByCampaignIdAndCustomId(@NonNull() String campaignId, @Nullable() String customUserId)
Get the counted view events for a given campaign ID and custom user ID
- Parameters:
campaignId- The campaign idcustomUserId- The custom user id
-
getViewCountsByCampaignIds
@NonNull() abstract Map<String, Integer> getViewCountsByCampaignIds(@NonNull() List<String> campaignsIds)
Tell how many times have campaigns been seen
- Parameters:
campaignsIds- A list containing the ids
-
getViewCountsByCampaignIdsAndCustomUserId
@NonNull() abstract Map<String, Integer> getViewCountsByCampaignIdsAndCustomUserId(@NonNull() List<String> campaignsIds, @Nullable() String customUserId)
Tell how many times have campaigns been seen for a given custom user id
- Parameters:
campaignsIds- A list containing the idscustomUserId- The custom user id
-
getCampaignLastOccurrence
abstract long getCampaignLastOccurrence(@NonNull() String campaignId)
Track how much time has passed since the last view of a campaign
- Parameters:
campaignId- The campaign id
-
getNumberOfViewEventsSince
abstract int getNumberOfViewEventsSince(long timestamp)
Get the number of view event tracked since a given timestamp
- Parameters:
timestamp- date (timestamp in ms)
-
-
-
-