Class Accounting.JobTracker

    • Field Detail

      • entry

        protected final PrintJobEntry entry
        The job description.
      • configuration

        protected final Configuration configuration
        The job configuration.
      • successTimer

        protected final com.codahale.metrics.Timer.Context successTimer
        The timer to use in case of success.
    • Constructor Detail

      • JobTracker

        protected JobTracker​(PrintJobEntry entry,
                             Configuration configuration)
        Constructor.
        Parameters:
        entry - the job description.
        configuration - the job configuration
    • Method Detail

      • onJobSuccess

        public long onJobSuccess​(PrintJob.PrintResult printResult)
        To be called when a job is a success.
        Parameters:
        printResult - Output file size in bytes
        Returns:
        the job duration in nanoseconds
      • onJobCancel

        public void onJobCancel()
        To be called when a job is canceled.
      • onJobError

        public void onJobError()
        To be called when a job is on error.