Problem with Google Calendar API "getTimes()" method

Posted by Raffo on Stack Overflow See other posts from Stack Overflow or by Raffo
Published on 2010-05-17T15:36:01Z Indexed on 2010/05/17 15:40 UTC
Read the original article Hit count: 204

Filed under:
|
|

I'm trying to get several informations from google calendar's API in JAVA. While trying to access to informations about the time of an event I got a problem. I do the following:

CalendarService myService = new CalendarService("project_name");
myService.setUserCredentials("user", "pwd");
URL feedUrl = new URL("http://www.google.com/calendar/feeds/default/private/full");
CalendarQuery q = new CalendarQuery(feedUrl);
CalendarEventFeed resultFeed = myService.query(q, CalendarEventFeed.class);
for (int i = 0; i < resultFeed.getEntries().size(); i++) {
              CalendarEventEntry g = resultFeed.getEntries().get(i);
List<When> t = g.getTimes();
//other operations
}

The list t obtained with getTimes() on a CalendarEventEntry is always empty and I can't figure out why. This seems strange to me since for a calendar event it should always exist a description of when it should happen... what am I missing??

© Stack Overflow or respective owner

Related posts about gwt

Related posts about google-calendar