コード例 #1
0
 @Override
 public void generatePrintForm(Reference reference, OutputStream outputStream) {
   ReportXml reportXml = new ReportXml();
   if (reference.getPrintTemplate() == null
       || reference.getPrintTemplate().getFileName() == null) {
     setDefaultPrintTemplate(reference);
   }
   reportXml.setTemplateFileName(reference.getPrintTemplate().getFileName());
   build(reportXml, studentDAO.findById(reference.getOwnerId()), reference.getPurpose());
   ReportPdfProcessor.getInstance().generate(reportXml, outputStream);
 }
コード例 #2
0
 @Override
 public void generatePrintForm(
     StudentDossier dossier, Student student, OutputStream outputStream) {
   ReportXml reportXml = new ReportXml();
   if (dossier.getPrintTemplate() == null || dossier.getPrintTemplate().getFileName() == null) {
     setDefaultPrintTemplate(dossier);
   }
   reportXml.setTemplateFileName(dossier.getPrintTemplate().getFileName());
   build(reportXml, student);
   ReportPdfProcessor.getInstance().generate(reportXml, outputStream);
 }
コード例 #3
0
  @Override
  public void generatePrintForm(List<Reference> references, OutputStream outputStream) {
    List<Report> reports = new ArrayList<Report>();

    for (Reference reference : references) {
      ReportXml reportXml = new ReportXml();
      if (reference.getPrintTemplate() == null
          || reference.getPrintTemplate().getFileName() == null) {
        setDefaultPrintTemplate(reference);
      }
      reportXml.setTemplateFileName(reference.getPrintTemplate().getFileName());
      build(reportXml, studentDAO.findById(reference.getOwnerId()), reference.getPurpose());
      reports.add(reportXml);
    }
    ReportPdfProcessor.getInstance().generate(reports, outputStream);
  }
コード例 #4
0
  @Override
  public void generatePrintForm(
      List<StudentDossier> dossiers, Student student, OutputStream outputStream) {
    List<Report> reports = new ArrayList<Report>();

    for (StudentDossier dossier : dossiers) {
      ReportXml reportXml = new ReportXml();
      if (dossier.getPrintTemplate() == null || dossier.getPrintTemplate().getFileName() == null) {
        setDefaultPrintTemplate(dossier);
      }
      reportXml.setTemplateFileName(dossier.getPrintTemplate().getFileName());
      build(reportXml, student);
      reports.add(reportXml);
    }
    ReportPdfProcessor.getInstance().generate(reports, outputStream);
  }