Class SalesReportGenerator

java.lang.Object
team75.model.SalesReportGenerator

public class SalesReportGenerator extends Object
Generates a PDF sales summary report.
  • Constructor Details

    • SalesReportGenerator

      public SalesReportGenerator()
      This class should never be initialized
  • Method Details

    • generate

      public byte[] generate(DB.SalesSummary summary, Timestamp start, Timestamp end) throws IOException
      Generates the report and returns the raw PDF bytes, ready to be written to a file or streamed as an HTTP response.
      Parameters:
      summary - the aggregated sales data
      start - report period start (inclusive)
      end - report period end (inclusive)
      Returns:
      PDF bytes
      Throws:
      IOException