1. /*
  2. * @(#)LoaderHandler.java 1.11 01/11/29
  3. *
  4. * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package java.rmi.server;
  8. import java.net.MalformedURLException;
  9. import java.net.URL;
  10. /**
  11. * <code>LoaderHandler</code> is an interface used internally by the RMI
  12. * runtime in previous implementation versions. It should never be accessed
  13. * by application code.
  14. *
  15. * @version 1.11, 11/29/01
  16. * @author Ann Wollrath
  17. * @since JDK1.1
  18. *
  19. * @deprecated no replacement
  20. */
  21. public interface LoaderHandler {
  22. /** package of system <code>LoaderHandler</code> implementation */
  23. final static String packagePrefix = "sun.rmi.server";
  24. /**
  25. * Loads a class from the location specified by the
  26. * <code>java.rmi.server.codebase</code> property.
  27. *
  28. * @param name the name of the class to load
  29. * @return the <code>Class</code> object representing the loaded class
  30. * @exception MalformedURLException
  31. * if the system property <b>java.rmi.server.codebase</b>
  32. * contains an invalid URL
  33. * @exception ClassNotFoundException
  34. * if a definition for the class could not
  35. * be found at the codebase location.
  36. * @since JDK1.1
  37. * @deprecated no replacement
  38. */
  39. Class loadClass(String name)
  40. throws MalformedURLException, ClassNotFoundException;
  41. /**
  42. * Loads a class from a URL.
  43. *
  44. * @param codebase the URL from which to load the class
  45. * @param name the name of the class to load
  46. * @return the <code>Class</code> object representing the loaded class
  47. * @exception MalformedURLException
  48. * if the <code>codebase</code> paramater
  49. * contains an invalid URL
  50. * @exception ClassNotFoundException
  51. * if a definition for the class could not
  52. * be found at the specified URL
  53. * @since JDK1.1
  54. * @deprecated no replacement
  55. */
  56. Class loadClass(URL codebase, String name)
  57. throws MalformedURLException, ClassNotFoundException;
  58. /**
  59. * Returns the security context of the given class loader.
  60. *
  61. * @param loader a class loader from which to get the security context
  62. * @return the security context
  63. * @since JDK1.1
  64. * @deprecated no replacement
  65. */
  66. Object getSecurityContext(ClassLoader loader);
  67. }