Package jminusminus

Class ByteClassLoader

java.lang.Object
java.lang.ClassLoader
jminusminus.ByteClassLoader

class ByteClassLoader extends ClassLoader
A class loader to be able to load a class from a byte stream.
  • Constructor Details

    • ByteClassLoader

      ByteClassLoader()
  • Method Details

    • setClassBytes

      public void setClassBytes(byte[] bytes)
      Sets the bytes representing the class.
      Parameters:
      bytes - bytes representing the class.
    • loadClass

      public Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException
      Loads the class with the specified fully qualified name.
      Overrides:
      loadClass in class ClassLoader
      Parameters:
      name - the fully qualified name of the class.
      resolve - if true then resolve the class.
      Throws:
      ClassNotFoundException - if the class could not be found.