本文整理汇总了Java中weibo4j.model.Comment类的典型用法代码示例。如果您正苦于以下问题:Java Comment类的具体用法?Java Comment怎么用?Java Comment使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Comment类属于weibo4j.model包,在下文中一共展示了Comment类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token =args[0];
Comments cm = new Comments();
cm.client.setToken(access_token);
try {
CommentWapper comment = cm.getCommentTimeline();
for(Comment c : comment.getComments()){
Log.logInfo(c.toString());
}
System.out.println(comment.getTotalNumber());
System.out.println(comment.getNextCursor());
System.out.println(comment.getNextCursor());
System.out.println(comment.getHasvisible());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例2: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = "2.00RQs9XC0gdCQY15dd6eda18QiojdE";
String id = args[1];
Comments cm =new Comments();
cm.client.setToken(access_token);
try {
CommentWapper comment = cm.getCommentById(id);
for(Comment c : comment.getComments()){
Log.logInfo(c.toString());
}
System.out.println(comment.getTotalNumber());
System.out.println(comment.getNextCursor());
System.out.println(comment.getNextCursor());
System.out.println(comment.getHasvisible());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例3: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token =args[0];
Comments cm = new Comments();
cm.client.setToken(access_token);
try {
CommentWapper comment = cm.getCommentMentions();
for(Comment c : comment.getComments()){
Log.logInfo(c.toString());
}
System.out.println(comment.getNextCursor());
System.out.println(comment.getPreviousCursor());
System.out.println(comment.getTotalNumber());
System.out.println(comment.getHasvisible());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例4: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
Comments cm = new Comments();
cm.client.setToken(access_token);
try {
CommentWapper comment = cm.getCommentToMe();
for(Comment c :comment.getComments()){
Log.logInfo(c.toString());
}
System.out.println(comment.getTotalNumber());
System.out.println(comment.getNextCursor());
System.out.println(comment.getNextCursor());
System.out.println(comment.getHasvisible());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例5: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
Comments cm = new Comments();
cm.client.setToken(access_token);
try {
CommentWapper comment = cm.getCommentByMe();
for(Comment c : comment.getComments()){
Log.logInfo(c.toString());
}
System.out.println(comment.getNextCursor());
System.out.println(comment.getPreviousCursor());
System.out.println(comment.getTotalNumber());
System.out.println(comment.getHasvisible());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例6: giveReply
import weibo4j.model.Comment; //导入依赖的package包/类
/**
* 根据相关信息,给指定用户的指定微博进行评论
* @param accessToken
* @param statusId
* @param comments
*/
public void giveReply(String accessToken,String statusId,String comments)
{
Comments cm = new Comments();
Timeline tm = new Timeline();
tm.setToken(accessToken);
cm.client.setToken(accessToken);
try {
Comment comment = cm.createComment(comments, statusId);
// Log.logInfo(comment.toString());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例7: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String cids = args[1];
Comments cm = new Comments(access_token);
try {
List<Comment> list = cm.destoryCommentBatch(cids);
for (Comment c : list) {
Log.logInfo(c.toString());
}
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例8: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String comments = args[1];
String id = args[2];
Comments cm = new Comments(access_token);
try {
Comment comment = cm.createComment(comments, id);
Log.logInfo(comment.toString());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例9: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String cid = args[1];
String id = args[2];
String comments = args[3];
Comments cm = new Comments(access_token);
try {
Comment com = cm.replyComment(cid, id, comments);
Log.logInfo(com.toString());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例10: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String cid = args[1];
Comments cm = new Comments(access_token);
try {
Comment com = cm.destroyComment(cid);
Log.logInfo(com.toString());
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例11: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String cids = args[1];
Comments cm = new Comments(access_token);
try {
List<Comment> comment = cm.getCommentShowBatch(cids);
for (Comment c : comment) {
Log.logInfo(c.toString());
}
} catch (WeiboException e) {
e.printStackTrace();
}
}
示例12: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String cids = args[1];
Comments cm = new Comments(access_token);
try {
List<Comment> list = cm.destoryCommentBatch(cids);
for (Comment c : list) {
Log.logInfo(c.toString());
}
}
catch (WeiboException e) {
e.printStackTrace();
}
}
示例13: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String comments = args[1];
String id = args[2];
Comments cm = new Comments(access_token);
try {
Comment comment = cm.createComment(comments, id);
Log.logInfo(comment.toString());
}
catch (WeiboException e) {
e.printStackTrace();
}
}
示例14: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String cid = args[1];
String id = args[2];
String comments = args[3];
Comments cm = new Comments(access_token);
try {
Comment com = cm.replyComment(cid, id, comments);
Log.logInfo(com.toString());
}
catch (WeiboException e) {
e.printStackTrace();
}
}
示例15: main
import weibo4j.model.Comment; //导入依赖的package包/类
public static void main(String[] args) {
String access_token = args[0];
String cid = args[1];
Comments cm = new Comments(access_token);
try {
Comment com = cm.destroyComment(cid);
Log.logInfo(com.toString());
}
catch (WeiboException e) {
e.printStackTrace();
}
}