Interface ReportService

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.util.List<ReportFormat> getFormats​(java.lang.String reportId)
      This method provides a list of formats supported by the report
      ReportParameters getParameters​(java.lang.String ReportId)
      This method retrieves the runtime parameters taken by the report
      void render​(java.lang.String ReportId, java.lang.String location, ReportFormat format, java.io.OutputStream outputStream)
      This method renders the report into a given output stream.
      java.lang.String run​(java.util.Map<java.lang.String,​java.lang.Object> reportParms, java.lang.String reportId)
      This method runs the report
      void runAndRender​(java.util.Map<java.lang.String,​java.lang.Object> reportParms, java.lang.String ReportId, ReportFormat format, java.io.OutputStream outputStream)
      This method runs the report and renders in into the given output stream with no intermediate steps
    • Method Detail

      • run

        java.lang.String run​(java.util.Map<java.lang.String,​java.lang.Object> reportParms,
                             java.lang.String reportId)
                      throws ReportException
        This method runs the report
        Parameters:
        reportParms - hashmap of parameters to be provided at runtime
        reportId - reportId as defined in database-reports.xml
        Returns:
        a String object.
        Throws:
        ReportException - if any.
      • getFormats

        java.util.List<ReportFormat> getFormats​(java.lang.String reportId)
        This method provides a list of formats supported by the report
        Parameters:
        reportId - reportId as defined in database-reports.xml
        Returns:
        a list of supported formats
      • render

        void render​(java.lang.String ReportId,
                    java.lang.String location,
                    ReportFormat format,
                    java.io.OutputStream outputStream)
             throws ReportException
        This method renders the report into a given output stream.
        Parameters:
        ReportId - reportId as defined in database-reports.xml
        location - location of the report on disk
        format - format to render the report
        outputStream - stream to render the resulting report
        Throws:
        ReportException - if any.
      • runAndRender

        void runAndRender​(java.util.Map<java.lang.String,​java.lang.Object> reportParms,
                          java.lang.String ReportId,
                          ReportFormat format,
                          java.io.OutputStream outputStream)
                   throws ReportException
        This method runs the report and renders in into the given output stream with no intermediate steps
        Parameters:
        ReportId - reportId as defined in database-reports.xml
        format - format to render the report
        outputStream - stream to render the resulting report
        reportParms - a HashMap object.
        Throws:
        ReportException - if any.
      • getParameters

        ReportParameters getParameters​(java.lang.String ReportId)
                                throws ReportException
        This method retrieves the runtime parameters taken by the report
        Parameters:
        ReportId - a String object.
        Returns:
        a ReportParameters object containing the parameters taken by the report
        Throws:
        ReportException