Class KarmaSourceLoader

java.lang.Object
java.lang.ClassLoader
java.security.SecureClassLoader
java.net.URLClassLoader
ml.karmaconfigs.api.common.karma.loader.KarmaSourceLoader
All Implemented Interfaces:
Closeable, AutoCloseable

@Deprecated public final class KarmaSourceLoader extends URLClassLoader
Deprecated.
read KarmaAppender notice
Karma source loader
  • Constructor Details

    • KarmaSourceLoader

      public KarmaSourceLoader(ClassLoader currentLoader, URL subJar)
      Deprecated.
      Initialize the source loader
      Parameters:
      currentLoader - the current class loader
      subJar - the jar containing bootstrap sources
    • KarmaSourceLoader

      public KarmaSourceLoader(ClassLoader currentLoader, File subJar) throws IOException
      Deprecated.
      Initialize the source loader
      Parameters:
      currentLoader - the current class loader
      subJar - the jar containing bootstrap sources
      Throws:
      IOException - if something goes wrong
    • KarmaSourceLoader

      public KarmaSourceLoader(ClassLoader currentLoader, Path subJar) throws IOException
      Deprecated.
      Initialize the source loader
      Parameters:
      currentLoader - the current class loader
      subJar - the jar containing bootstrap sources
      Throws:
      IOException - if something goes wrong
  • Method Details

    • addJarToClasspath

      public void addJarToClasspath(URL url)
      Deprecated.
      Add a source to the current path
      Parameters:
      url - the source file url
    • deleteJarResource

      public void deleteJarResource()
      Deprecated.
      Delete the jar sources file
    • instantiate

      public <T> SourceBootstrap instantiate(String bootstrapClass, Class<T> loaderPluginType, T loaderPlugin)
      Deprecated.
      Instantiate the bootstrap class
      Type Parameters:
      T - the return type
      Parameters:
      bootstrapClass - the bootstrap class
      loaderPluginType - the loader type
      loaderPlugin - the loader
      Returns:
      the instance
    • instantiate

      public <T> SourceBootstrap instantiate(String bootstrapClass)
      Deprecated.
      Instantiate the bootstrap class
      Type Parameters:
      T - the return type
      Parameters:
      bootstrapClass - the bootstrap class
      Returns:
      the instance
    • closeLoader

      public void closeLoader()
      Deprecated.
      Close this source loader