开发者

Google-API Calendar Feed for Java

I'm currently using the new Google API 1.5 beta, and I can't find any examples for retrieving a calendar feed. The examples posted here only seem to provide a list of calendars per account and not their events. Is the old GData API the only way to retrieve a calendar feed right now? And if so, is it wor开发者_JAVA技巧th waiting for this feature to appear in the new API if I only want to retrieve an event feed?


Did some digging around in the other non-Android examples and found this to work:

CalendarUrl url = new CalendarUrl(calendar.getEventFeedLink());
try {
  EventFeed feed = client.eventFeed().list().execute(url);
  for(EventEntry entry : feed.getEntries()) {
    // etc....
  }
}
catch(IOException e) {
  e.printStackTrace();
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜