DefaultLoaderRepository.java |
/* * JBoss, the OpenSource EJB server * * Distributable under LGPL license. * See terms of license at gnu.org. */ package javax.management; /** Keeps the list of Class Loaders registered in the MBean Server. It provides * the necessary methods to load classes using the registered Class Loaders. * * This deprecated class is maintained for compatibility. In previous versions * of JMX, there was one DefaultLoaderRepository shared by all MBean servers. * As of JMX 1.2, that functionality is approximated by using * MBeanServerFactory.findMBeanServer(java.lang.String) to find all known MBean * servers, and consulting the ClassLoaderRepository of each one. It is * strongly recommended that code referencing DefaultLoaderRepository be * rewritten. * * @deprecated Use MBeanServer.getClassLoaderRepository()} instead. * * @author Scott.Stark@jboss.org * @version $Revision: 1.1 $ */ public class DefaultLoaderRepository { public DefaultLoaderRepository() { } public static Class loadClass(String className) throws ClassNotFoundException { throw new ClassNotFoundException("Do not use, see MBeanServer.getClassLoaderRepository()"); } public static Class loadClassWithout(ClassLoader loader, String className) throws ClassNotFoundException { throw new ClassNotFoundException("Do not use, see MBeanServer.getClassLoaderRepository()"); } }
DefaultLoaderRepository.java |