Skip to content

Instantly share code, notes, and snippets.

@javier-tarazaga
Created April 21, 2015 07:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save javier-tarazaga/0c141ac7587afff00965 to your computer and use it in GitHub Desktop.
Save javier-tarazaga/0c141ac7587afff00965 to your computer and use it in GitHub Desktop.
Adobe Successfully added to favourites
/**
* Track the action of a successful added to favourites user action.
*
* @param contentId - The content id of the item just added to favourites
*/
public void trackAddedToFavourites(String contentId) {
Preconditions.checkNotNull(contentId);
HashMap<String, Object> contextData = new HashMap<>();
contextData.put("video.id", contentId);
contextData.put("action.event", "favourites");
Analytics.trackAction("Add to favorites", contextData);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment