Class ThreadPools


  • public class ThreadPools
    extends java.lang.Object
    Provides access to default Executors to be used
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.util.concurrent.Executor getMainExecutor()
      Executor for anything that that touches Renderer state
      static java.util.concurrent.Executor getThreadPoolExecutor()
      Default background Executor for async operations including file reading.
      static void setMainExecutor​(java.util.concurrent.Executor executor)  
      static void setThreadPoolExecutor​(java.util.concurrent.Executor executor)
      Sets the default background Executor.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getMainExecutor

        public static java.util.concurrent.Executor getMainExecutor()
        Executor for anything that that touches Renderer state
      • setMainExecutor

        public static void setMainExecutor​(java.util.concurrent.Executor executor)
        Parameters:
        executor - provides access to the main thread.
      • getThreadPoolExecutor

        public static java.util.concurrent.Executor getThreadPoolExecutor()
        Default background Executor for async operations including file reading.
      • setThreadPoolExecutor

        public static void setThreadPoolExecutor​(java.util.concurrent.Executor executor)
        Sets the default background Executor.

        Tasks may be long running. This should not include the main thread