Back to project page Gcal_Importer.
The source code is released under:
Apache License
If you think the Android project Gcal_Importer listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package net.crappo.android.androics; // w w w . j a va 2 s . c om import java.io.FileInputStream; import java.util.ArrayList; import net.fortuna.ical4j.data.CalendarBuilder; import net.fortuna.ical4j.model.Calendar; import net.fortuna.ical4j.model.Property; public class Model4Top { public ArrayList<Property> calNames; public Model4Top() { calNames = new ArrayList<Property>(); } public void addCalName(String pathStr) { Calendar calendar = null; try { // TopActivity????????????????????????????????????????????????????(????Property?Component???????) FileInputStream fin = new FileInputStream(pathStr); CalendarBuilder builder = new CalendarBuilder(); calendar = builder.build(fin); calNames.add(calendar.getProperties().getProperty("X-WR-CALNAME")); } catch (Exception e) { e.printStackTrace(); } } }