furryhamster
Lt. Commander
- Registriert
- Okt. 2008
- Beiträge
- 1.101
Hi,
ich apache Camel erstellt bei mir aus einer Ical Datei ein ical4j calendar. Wenn ich jetzt auf ein Property von einem Event zugreife, welches in der Ical nicht gesetzt war, dann bricht das komplette Programm ohne Exception ab. Dabei ist ist egal ob ich auf das .getValue(), .validate oder .isCalendarProperty zugreife.
Hier mal ein Beispiel:
Die UID zeigt er noch an. Bei Location hört das Programm einfach auf (ohne Exception). Wie kann ich dies handeln? Es würde mir schon reichen wenn einfach ein "" setzen könnte.
ich apache Camel erstellt bei mir aus einer Ical Datei ein ical4j calendar. Wenn ich jetzt auf ein Property von einem Event zugreife, welches in der Ical nicht gesetzt war, dann bricht das komplette Programm ohne Exception ab. Dabei ist ist egal ob ich auf das .getValue(), .validate oder .isCalendarProperty zugreife.
Hier mal ein Beispiel:
Code:
for (Object o : calendar.getComponents("VEVENT")) {
Component c = (Component)o;
customIcal = new customIcal();
System.out.println(c.getProperty("UID").getValue());
System.out.println(c.getProperty("LOCATION").getValue());
}
Die UID zeigt er noch an. Bei Location hört das Programm einfach auf (ohne Exception). Wie kann ich dies handeln? Es würde mir schon reichen wenn einfach ein "" setzen könnte.