我有一个通过 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());
谁能帮我吗 ?
最好的问候,谢谢!