com.google.api.services.youtube.model.VideoListResponse

Here are the examples of the java api class com.google.api.services.youtube.model.VideoListResponse taken from open source projects.

1. YoutubeUserActivityCollector#getVideoList()

View license
/**
     * Given a Youtube videoId, return the relevant Youtube Video object
     * @param videoId
     * @return
     * @throws IOException
     */
List<Video> getVideoList(String videoId) throws IOException {
    VideoListResponse videosListResponse = this.youtube.videos().list("snippet,statistics").setId(videoId).setKey(config.getApiKey()).execute();
    if (videosListResponse.getItems().size() == 0) {
        LOGGER.debug("No Youtube videos found for videoId: {}", videoId);
        return Lists.newArrayList();
    }
    return videosListResponse.getItems();
}