YouTubeService service = new YouTubeService("MyApp");
String videoEntryUrl = "http://gdata.youtube.com/feeds/api/videos/nU9dinwMyHo";
VideoEntry videoEntry = service.getEntry(new URL(videoEntryUrl), VideoEntry.class);
String commentUrl = videoEntry.getComments().getFeedLink().getHref();
CommentFeed commentFeed = service.getFeed(new URL(commentUrl), CommentFeed.class);
for(CommentEntry comment : commentFeed.getEntries()) {
System.out.println(comment.getPlainTextContent());
特定のビデオの YouTube コメントを取得するコードを次に示します。このコードを使用して約 25 件のコメントを取得できますが、ビデオからすべてのコメントを取得するにはどうすればよいですか?