/** * Adds a comment * @param comment the comment that should be added * @return true if the comment was added, false otherwise * @deprecated work on the {@code Comments} object directly instead of using this method */ @Deprecated public boolean addComment(Comment comment) { if (getComments() != null) { return getComments().addData(comment); } return false; }
/** * The number of likes on this video. * * you have to fetch the video id with <code>?fields=likes.summary(true)</code> in order to speed up the likes count * generation, you may use <code>?fields=likes.limit(1).summary(true)</code>, so only 1 like is fetched, but the * complete summary * * @return The number of likes on this video. */ public Long getLikesCount() { if (getLikes() != null) { return getLikes().getTotalCount(); } return 0L; }
/** * Adds a comment * @param comment the comment that should be added * @return true if the comment was added, false otherwise * @deprecated work on the {@code Comments} object directly instead of using this method */ @Deprecated public boolean removeComment(Comment comment) { if (getComments() != null) { return getComments().removeData(comment); } return false; }
/** * The number of comments of this video. * * you have to fetch the video id with <code>?fields=comments.summary(true)</code> in order to speed up the comments * count generation, you may use <code>?fields=comments.limit(1).summary(true)</code>, so only 1 comment is fetched, * but the complete summary * * @return The number of comments of this video. */ public Long getCommentsCount() { if (getComments() != null) { return getComments().getTotalCount(); } return 0L; }