1. /*
  2. * @(#)RegistryHandler.java 1.14 04/05/18
  3. *
  4. * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package java.rmi.registry;
  8. import java.rmi.RemoteException;
  9. import java.rmi.UnknownHostException;
  10. /**
  11. * <code>RegistryHandler</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.14, 05/18/04
  16. * @author Ann Wollrath
  17. * @since JDK1.1
  18. * @deprecated no replacement
  19. */
  20. @Deprecated
  21. public interface RegistryHandler {
  22. /**
  23. * Returns a "stub" for contacting a remote registry
  24. * on the specified host and port.
  25. *
  26. * @deprecated no replacement. As of the Java 2 platform v1.2, RMI no
  27. * longer uses the <code>RegistryHandler</code> to obtain the registry's
  28. * stub.
  29. * @param host name of remote registry host
  30. * @param port remote registry port
  31. * @return remote registry stub
  32. * @throws RemoteException if a remote error occurs
  33. * @throws UnknownHostException if unable to resolve given hostname
  34. */
  35. @Deprecated
  36. Registry registryStub(String host, int port)
  37. throws RemoteException, UnknownHostException;
  38. /**
  39. * Constructs and exports a Registry on the specified port.
  40. * The port must be non-zero.
  41. *
  42. * @deprecated no replacement. As of the Java 2 platform v1.2, RMI no
  43. * longer uses the <code>RegistryHandler</code> to obtain the registry's
  44. * implementation.
  45. * @param port port to export registry on
  46. * @return registry stub
  47. * @throws RemoteException if a remote error occurs
  48. */
  49. @Deprecated
  50. Registry registryImpl(int port) throws RemoteException;
  51. }