Continuous Integration: | |
Code Coverage: | |
Maven Central: | |
Chat Room: | |
License: |
biweekly is an iCalendar library written in Java. The project aims to provide a well documented, easy to use API for reading and writing iCalendar data.
Downloads | Javadocs | Maven | Documentation
String str =
"BEGIN:VCALENDAR\r\n" +
"VERSION:2.0\r\n" +
"PRODID:-//Microsoft Corporation//Outlook 14.0 MIMEDIR//EN\r\n" +
"BEGIN:VEVENT\r\n" +
"UID:0123\r\n" +
"DTSTAMP:20130601T080000Z\r\n" +
"SUMMARY;LANGUAGE=en-us:Team Meeting\r\n" +
"DTSTART:20130610T120000Z\r\n" +
"DURATION:PT1H\r\n" +
"RRULE:FREQ=WEEKLY;INTERVAL=2\r\n" +
"END:VEVENT\r\n" +
"END:VCALENDAR\r\n";
ICalendar ical = Biweekly.parse(str).first();
VEvent event = ical.getEvents().get(0);
String summary = event.getSummary().getValue();
ICalendar ical = new ICalendar();
VEvent event = new VEvent();
Summary summary = event.setSummary("Team Meeting");
summary.setLanguage("en-us");
Date start = ...
event.setDateStart(start);
Duration duration = new Duration.Builder().hours(1).build();
event.setDuration(duration);
Recurrence recur = new Recurrence.Builder(Frequency.WEEKLY).interval(2).build();
event.setRecurrenceRule(recur);
ical.addEvent(event);
String str = Biweekly.write(ical).go();
- Simple, intuitive API (see Examples).
- Android compatibility.
- Full compliance with iCalendar and vCalendar specifications (see Supported Specifications).
- Supports XML and JSON formats (see Supported Specifications).
- Full timezone support (uses tzurl.org for timezone definitions).
- Extensive unit test coverage.
- Low Java version requirement (1.5 or above, 1.6 for JSON support).
- No dependencies (except when JSON support is required, see Dependencies).
<dependency>
<groupId>net.sf.biweekly</groupId>
<artifactId>biweekly</artifactId>
<version>0.4.6</version>
</dependency>
biweekly uses Maven as its build tool, and adheres to its convensions.
To build the project: mvn compile
To run the unit tests: mvn test
To build a JAR: mvn package
You have some options:
- Issue tracker
- Gitter chat room
- Post a question to StackOverflow (use the
ical
tag). - Email me directly: [email protected]
Please submit bug reports and feature requests to the issue tracker.
If you'd like to help improve the accuracy of biweekly's parsing engine, please submit samples of iCalendar files using this form. All contributions are greatly appreciated.
This project was born on June 23, 2013 on Sourceforge. It migrated to Github on November 22, 2015.