URLで取得したVCalendarがあります:
PRODID: test_online
VERSION: 1.0
METHOD:PUBLISH
BEGIN:VEVENT
SUMMARY: It's a test
DESCRIPTION: Test an vcalendar parser
LOCATION:
DTSTART: 11/6/2011 3:00:00 PM
DTEND: 11/10/2011 11:59:00 PM
CATEGORIES: Other tests
END:VEVENT
END:VCALENDAR
文字列を分割する以外に、そのような vcalendar を解析する方法はありますか? Ical4j を試してみましたが、常に次のエラーが発生しました。
The exception contained within MappableContainerException could not be mapped to a response, re-throwing to the HTTP container
私のコードは次のとおりです。
StringReader s = new StringReader(vcal);
CalendarBuilder builder = new CalendarBuilder();
Calendar c = builder.build(s);
System.out.println(c.toString());
誰でも私を助けることができますか?
よろしくお願いします!