public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof Comment)) return false; Comment other = (Comment) o; if (id != 0 && id == other.getId()) return true; return message.equals(other.getMessage()) && (actorId != null ? actorId.equals(other.getActorId()) : other.getActorId() == null) && (taskInstance != null ? taskInstance.equals(other.getTaskInstance()) : token != null ? token.equals(other.getToken()) : false); }
public void addComment(Comment comment) { if (comment != null) { if (comments == null) comments = new ArrayList(); comments.add(comment); comment.setTaskInstance(this); if (token != null) { comment.setToken(token); token.addComment(comment); } } }
private static List<FBComment> getCommentFromPost(FacebookClient client, String post_id){ List<String> comments = new ArrayList<FBComment>(); Connection<Comment> allComments = client.fetchConnection(post_id+"/comments", Comment.class); for(List<Comment> postcomments : allComments){ for (Comment comment : postcomments){ long likes = comment.getLikeCount()==null?(comment.getLikes()==null?0:comment.getLikes()):comment.getLikeCount(); comments.add(comment.getMessage()+" - "+likes); } } return comments; }
Connection<Comment> commentsConnection= fbClient.fetchConnection(post.getId()+"/comments",com.restfb.types.Comment.class); if(commentsConnection!=null) { Iterator<List<Comment>> commentsIterator=commentsConnection.iterator(); while(commentsIterator.hasNext()) { List<Comment> comments= commentsIterator.next(); for(Comment comment:comments) { String message=comment.getMessage(); } } }
public void addComment(String message) { addComment(new Comment(message)); }
public void addComment(Comment comment) { if (comments == null) comments = new ArrayList(); comments.add(comment); comment.setToken(this); }
public void addComment(String message) { addComment(new Comment(message)); }
public void addComment(Comment comment) { if (comments == null) comments = new ArrayList(); comments.add(comment); comment.setToken(this); }
public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof Comment)) return false; Comment other = (Comment) o; if (id != 0 && id == other.getId()) return true; return message.equals(other.getMessage()) && (actorId != null ? actorId.equals(other.getActorId()) : other.getActorId() == null) && (taskInstance != null ? taskInstance.equals(other.getTaskInstance()) : token != null ? token.equals(other.getToken()) : false); }
public void addComment(Comment comment) { if (comment != null) { if (comments == null) comments = new ArrayList(); comments.add(comment); comment.setTaskInstance(this); if (token != null) { comment.setToken(token); token.addComment(comment); } } }
public void addComment(String message) { addComment(new Comment(message)); }
public void addComment(String message) { addComment(new Comment(message)); }