Interface ITask<V>

  • All Superinterfaces:
    java.util.concurrent.Callable<V>, java.util.concurrent.Future<V>
    All Known Subinterfaces:
    IScheduledTask<V>
    All Known Implementing Classes:
    DefaultScheduledTask, ListenableTask

    public interface ITask<V>
    extends java.util.concurrent.Future<V>, java.util.concurrent.Callable<V>
    • Method Detail

      • onComplete

        default ITask<V> onComplete​(java.util.function.BiConsumer<ITask<V>,​V> consumer)
      • onComplete

        default ITask<V> onComplete​(java.util.function.Consumer<V> consumer)
      • onFailure

        default ITask<V> onFailure​(java.util.function.BiConsumer<ITask<V>,​java.lang.Throwable> consumer)
      • onFailure

        default ITask<V> onFailure​(java.util.function.Consumer<java.lang.Throwable> consumer)
      • onCancelled

        default ITask<V> onCancelled​(java.util.function.Consumer<ITask<V>> consumer)
      • clearListeners

        ITask<V> clearListeners()
      • getCallable

        java.util.concurrent.Callable<V> getCallable()
      • getDef

        V getDef​(V def)
      • get

        V get​(long time,
              java.util.concurrent.TimeUnit timeUnit,
              V def)