private void write(BufferedWriter out)
  {
    for (String s : _dateList.keySet()) {
      TemperatureDate td = _dateList.get(s);
     
      StringBuffer sb = new StringBuffer();
      sb.append("db." + JSONWriter.COLLECTION_NAME + ".insert({");
      sb.append("stationId: \"" + _stationId + "\"");
      sb.append(", stationName: \"" + Stations.getName(_stationId) + "\"");
      sb.append(", latitude: " + Stations.getLat(_stationId));
      sb.append(", longitude: " + Stations.getLon(_stationId));
      sb.append(", elevation: " + Stations.getElevation(_stationId));
      sb.append(", state: \"" + Stations.getState(_stationId) + "\"");
      sb.append(", year: \"" + Integer.parseInt(s.substring(0,4)) + "\"");
      sb.append(", month: \"" + Integer.parseInt(s.substring(4,6)) + "\"");
      sb.append(", day: \"" + Integer.parseInt(s.substring(6,8)) + "\"");
      sb.append(", min: " + td._min);
      sb.append(", max: " + td._max);
      sb.append("});\n");
      
      try {
        out.write(sb.toString());
      } catch (IOException e) {
        e.printStackTrace();
      }
      
    }
  }