Interface TryExecutor

All Superinterfaces:
Executor
All Known Implementing Classes:
ExecutorSizedThreadPool, ExecutorThreadPool, MonitoredQueuedThreadPool, QueuedThreadPool, ReservedThreadExecutor, TryExecutor.NoTryExecutor

@Deprecated(since="2021-05-27") public interface TryExecutor extends Executor
Deprecated.
The Eclipse Jetty and Apache Felix Http Jetty packages are no longer supported.
A variation of Executor that can confirm if a thread is available immediately
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static class 
    Deprecated.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final TryExecutor
    Deprecated.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    Deprecated.
     
    default void
    Deprecated.
     
    boolean
    Deprecated.
    Attempt to execute a task.
  • Field Details

  • Method Details

    • tryExecute

      boolean tryExecute(Runnable task)
      Deprecated.
      Attempt to execute a task.
      Parameters:
      task - The task to be executed
      Returns:
      True IFF the task has been given directly to a thread to execute. The task cannot be queued pending the later availability of a Thread.
    • execute

      default void execute(Runnable task)
      Deprecated.
      Specified by:
      execute in interface Executor
    • asTryExecutor

      static TryExecutor asTryExecutor(Executor executor)
      Deprecated.