for(int i=0; i< collection.size(); i++) { this.docAddPlanObject(collection.get(i)); }
  public void writeDocument(OutputStream os) {      for(int i=0; i< collection.size(); i++) {       this.docAddPlanObject(collection.get(i));    }    try {      PrintWriter pw = new PrintWriter(os);      doc.print(pw);    } catch (Exception e) {      e.printStackTrace();    }  }