/**
   * Attempts to unload class, it only unloads the locally loaded classes by JCL
   *
   * @param className
   */
  public void unloadClass(String className) {
    if (logger.isLoggable(Level.FINEST)) logger.finest("Unloading class " + className);

    if (classes.containsKey(className)) {
      if (logger.isLoggable(Level.FINEST)) logger.finest("Removing loaded class " + className);
      classes.remove(className);
      try {
        classpathResources.unload(formatClassName(className));
      } catch (ResourceNotFoundException e) {
        throw new JclException(
            "Something is very wrong!!!"
                + "The locally loaded classes must be in synch with ClasspathResources",
            e);
      }
    } else {
      try {
        classpathResources.unload(formatClassName(className));
      } catch (ResourceNotFoundException e) {
        throw new JclException(
            "Class could not be unloaded " + "[Possible reason: Class belongs to the system]", e);
      }
    }
  }
 /**
  * Returns all loaded classes and resources
  *
  * @return Map
  */
 public Map<String, byte[]> getLoadedResources() {
   return classpathResources.getResources();
 }
  /**
   * Reads the class bytes from different local and remote resources using ClasspathResources
   *
   * @param className
   * @return byte[]
   */
  protected byte[] loadClassBytes(String className) {
    className = formatClassName(className);

    return classpathResources.getResource(className);
  }
 /**
  * Loads local/remote resource
  *
  * @param url
  */
 public void add(URL url) {
   classpathResources.loadResource(url);
 }
 /**
  * Loads classes from InputStream
  *
  * @param jarStream
  */
 public void add(InputStream jarStream) {
   classpathResources.loadJar(jarStream);
 }
 /**
  * Loads local/remote resource
  *
  * @param resourceName
  */
 public void add(String resourceName) {
   classpathResources.loadResource(resourceName);
 }