Interface MonitoredCallable<T>

  • Type Parameters:
    T - the type of result
    All Superinterfaces:
    Callable<T>

    public interface MonitoredCallable<T>
    extends Callable<T>
    Extension of Callable that provides a way to get its current status prior to execution completion. Note that the type of status must be the same as the final result: this has the nice property that querying the corresponding MonitoredFuture for status following completion will return the final result.
    • Method Detail

      • getStatistics

        List<RuntimeStatistic<?>> getStatistics()
        Returns the statistics for this callable
        Returns:
        the statistics for this callable
      • getStatus

        T getStatus()
        Returns the partial status or the final result if already complete. This method should not ever throw an exception. It should always be possible to obtain a status, even if callable itself fails.
        Returns:
        the partial status