Class CustomContextClassLoaderExecutor


  • class CustomContextClassLoaderExecutor
    extends java.lang.Object
    Since:
    1.0
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.util.Optional<java.lang.ClassLoader> customClassLoader  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private static void close​(java.lang.AutoCloseable customClassLoader)  
      (package private) <T> T invoke​(java.util.function.Supplier<T> supplier)  
      private <T> T replaceThreadContextClassLoaderAndInvoke​(java.lang.ClassLoader customClassLoader, java.util.function.Supplier<T> supplier)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • customClassLoader

        private final java.util.Optional<java.lang.ClassLoader> customClassLoader
    • Constructor Detail

      • CustomContextClassLoaderExecutor

        CustomContextClassLoaderExecutor​(java.util.Optional<java.lang.ClassLoader> customClassLoader)
    • Method Detail

      • invoke

        <T> T invoke​(java.util.function.Supplier<T> supplier)
      • replaceThreadContextClassLoaderAndInvoke

        private <T> T replaceThreadContextClassLoaderAndInvoke​(java.lang.ClassLoader customClassLoader,
                                                               java.util.function.Supplier<T> supplier)
      • close

        private static void close​(java.lang.AutoCloseable customClassLoader)