Back to project page InstagramViewer.
The source code is released under:
MIT License
If you think the Android project InstagramViewer listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.codepath.instagramviewer; /*w w w. j a v a2s . c o m*/ import android.text.format.DateUtils; public class InstagramPhoto { private String username; private Long createdTime; private String userProfilePicUrl; private String caption; private String imageUrl; private int imageHeight; private String likesCount; private String lastCommentUsername; private String lastComment; private String secondLastCommentUsername; private String secondLastComment; public String getUsername() { return username; } public void setUsername(String username) { this.username = username; } public Long getCreatedTime() { return createdTime; } public void setCreatedTime(Long createdTime) { this.createdTime = createdTime; } public String getUserProfilePicUrl() { return userProfilePicUrl; } public void setUserProfilePicUrl(String userProfilePicUrl) { this.userProfilePicUrl = userProfilePicUrl; } public String getCaption() { return caption; } public void setCaption(String caption) { this.caption = caption; } public String getImageUrl() { return imageUrl; } public void setImageUrl(String imageUrl) { this.imageUrl = imageUrl; } public int getImageHeight() { return imageHeight; } public void setImageHeight(int imageHeight) { this.imageHeight = imageHeight; } public String getLikesCount() { return likesCount; } public void setLikesCount(String likesCount) { this.likesCount = likesCount; } public String getLastCommentUsername() { return lastCommentUsername; } public void setLastCommentUsername(String lastCommentUsername) { this.lastCommentUsername = lastCommentUsername; } public String getLastComment() { return lastComment; } public void setLastComment(String lastComment) { this.lastComment = lastComment; } public String getSecondLastCommentUsername() { return secondLastCommentUsername; } public void setSecondLastCommentUsername(String secondLastCommentUsername) { this.secondLastCommentUsername = secondLastCommentUsername; } public String getSecondLastComment() { return secondLastComment; } public void setSecondLastComment(String secondLastComment) { this.secondLastComment = secondLastComment; } public String getRelativeTime(){ return DateUtils.getRelativeTimeSpanString(createdTime * 1000, System.currentTimeMillis(), DateUtils.FORMAT_ABBREV_RELATIVE).toString(); } }