org.modeshape.common.util

## Class DelegatingClassLoader

- java.lang.Object
- - java.lang.ClassLoader
  - - java.security.SecureClassLoader
    - - java.net.URLClassLoader
      - - org.modeshape.common.util.DelegatingClassLoader

- All Implemented Interfaces:
    Closeable, AutoCloseable

      public final class DelegatingClassLoader
      extends URLClassLoader

  Class loader which contains a list of classloaders to which it delegates each operation. If none of the delegates are able to perform the operation, it delegates to the super-class( `URLClassLoader` ) which has most of the classloader methods properly implemented.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DelegatingClassLoader(ClassLoader parent, List<? extends ClassLoader> delegates)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected Class<?>` | `findClass(String name)`
    `URL` | `findResource(String name)`

    - ### Methods inherited from class java.net.URLClassLoader

      `addURL, close, definePackage, findResources, getPermissions, getResourceAsStream, getURLs, newInstance, newInstance`

    - ### Methods inherited from class java.security.SecureClassLoader

      `defineClass, defineClass`

    - ### Methods inherited from class java.lang.ClassLoader

      `clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getResource, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, loadClass, registerAsParallelCapable, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### DelegatingClassLoader

          public DelegatingClassLoader(ClassLoader parent,
                               List<? extends ClassLoader> delegates)

  - ### Method Detail

    - #### findClass

          protected Class<?> findClass(String name)
                                throws ClassNotFoundException

      Overrides:
        `findClass` in class `URLClassLoader`
      Throws:
        `ClassNotFoundException`

    - #### findResource

          public URL findResource(String name)

      Overrides:
        `findResource` in class `URLClassLoader`

Copyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.