public Appointment scheduleAppointment(Appointment appt) {

    if (appt.getUuid() == null || "".equals(appt.getUuid())) {
      appt.setUuid(UUID.randomUUID().toString());
    }

    // appointments.put(appt.getId(), appt);
    appt = dao.saveAppointment(appt);

    return appt;
  }
  public List<Appointment> getAppointments(Date date) {

    return dao.getAppointments(date);
    /*
    List<Appointment> appts = new LinkedList<Appointment>();
    for (Appointment appt : appointments.values()) {
    	String startDate = dateFormat.format(appt.getStartDatetime());
    	String endDate = dateFormat.format(appt.getEndDatetime());
    	String inputDate = dateFormat.format(date);
    	if (inputDate.equals(startDate) || inputDate.equals(endDate)) {
    		appts.add(appt);
    	}
    }
    return appts;
    */
  }
  public void removeAppointment(Appointment appt) {
    dao.purgeappointment(appt);
    // appointments.remove(appt.getId());

  }
 public Appointment getAppointment(Integer id) {
   // return appointments.get(id);
   return dao.getAppointment(id);
 }