Könnte "Terminplan" so aussehen bin mir nicht sicher
import java.util.Iterator;
import java.util.Vector;
/public class Terminplan {
private Vector Termine;
protected Terminplan() {
Termine = new Vector();
}
public void eintragen(Termin t) {
if(frei(t)) Termine.add(t);
}
public void loeschen(Termin t) throws Exception{
if(Termine.isEmpty()) throw new Exception();
else Termine.remove(t);
}
public boolean frei(Termin t){
boolean antwort = true;
if(Termine.isEmpty());
else{
for(Iterator it = Termine.iterator(); it.hasNext()

{
if(((Termin)it.next()).kollidiert(t)){
antwort = false;
break;
}
}
}
return antwort;
}
public Terminplan freieTermineImZeitraum(Termin von, Termin bis, Terminplan neu){
//TODO: Frei Termine im angegeben Zeitraum suchen und in antwort eintragen;
Terminplan antwort = neu;
return antwort;
}
public static void main(String args[]) throws java.text.ParseException{
Termin t1 = new Termin("15.06.2004 11:00","15.06.2004 13:00");
Termin t2 = new Termin("15.06.2004 14:30","15.06.2004 19:23");
Termin t3 = new Termin("15.06.2004 12:00","15.06.2004 14:00");
Terminplan tp = new Terminplan();
tp.eintragen(t1);
System.out.println(tp.frei(t2));
System.out.println(tp.frei(t3));
}
}