1. /*
  2. * @(#)RegistryHandler.java 1.10 00/02/02
  3. *
  4. * Copyright 1997-2000 Sun Microsystems, Inc. All Rights Reserved.
  5. *
  6. * This software is the proprietary information of Sun Microsystems, Inc.
  7. * Use is subject to license terms.
  8. *
  9. */
  10. package java.rmi.registry;
  11. import java.rmi.RemoteException;
  12. import java.rmi.UnknownHostException;
  13. /**
  14. * <code>RegistryHandler</code> is an interface used internally by the RMI
  15. * runtime in previous implementation versions. It should never be accessed
  16. * by application code.
  17. *
  18. * @version 1.10, 02/02/00
  19. * @author Ann Wollrath
  20. * @since JDK1.1
  21. * @deprecated no replacement
  22. */
  23. public interface RegistryHandler {
  24. /**
  25. * Returns a "stub" for contacting a remote registry
  26. * on the specified host and port.
  27. *
  28. * @deprecated no replacement. As of the Java 2 platform v1.2, RMI no
  29. * longer uses the <code>RegistryHandler</code> to obtain the registry's
  30. * stub.
  31. * @param host name of remote registry host
  32. * @param port remote registry port
  33. * @return remote registry stub
  34. * @throws RemoteException if a remote error occurs
  35. * @throws UnknownHostException if unable to resolve given hostname
  36. */
  37. Registry registryStub(String host, int port)
  38. throws RemoteException, UnknownHostException;
  39. /**
  40. * Constructs and exports a Registry on the specified port.
  41. * The port must be non-zero.
  42. *
  43. * @deprecated no replacement. As of the Java 2 platform v1.2, RMI no
  44. * longer uses the <code>RegistryHandler</code> to obtain the registry's
  45. * implementation.
  46. * @param port port to export registry on
  47. * @return registry stub
  48. * @throws RemoteException if a remote error occurs
  49. */
  50. Registry registryImpl(int port) throws RemoteException;
  51. }