Class DynamicClassLoader

All Implemented Interfaces:
Closeable, AutoCloseable

public class DynamicClassLoader extends URLClassLoader
This is a basic URL classloader for loading new resources dynamically. It allows public access to the addURL() method. It also adds a convenience method to update the current thread classloader
  • Constructor Details

  • Method Details

    • addURL

      public void addURL(URL url)
      Overrides:
      addURL in class URLClassLoader
    • updateLoader

      public static void updateLoader(URL[] urls)
      Returns list of URLs to add to the thread's classloader.
      Parameters:
      urls - - list of URLs to add to the thread's classloader