Class RMILocalClientSocketFactory

  • All Implemented Interfaces:
    java.io.Serializable, java.rmi.server.RMIClientSocketFactory

    public class RMILocalClientSocketFactory
    extends java.lang.Object
    implements java.rmi.server.RMIClientSocketFactory, java.io.Serializable
    This factory mints client-side sockets. I've created one so the $%^&* rmi world doesn't attempt to connect to anything other than localhost (127.0.0.1).
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String _rcsid  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.net.Socket createSocket​(java.lang.String host, int port)
      The method that mints a socket of the right kind.
      boolean equals​(java.lang.Object o)
      The contract makes us implement equals and hashcode
      int hashCode()
      Hashcode consistent with equals()
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RMILocalClientSocketFactory

        public RMILocalClientSocketFactory()
        Constructor
    • Method Detail

      • createSocket

        public java.net.Socket createSocket​(java.lang.String host,
                                            int port)
                                     throws java.io.IOException
        The method that mints a socket of the right kind.
        Specified by:
        createSocket in interface java.rmi.server.RMIClientSocketFactory
        Throws:
        java.io.IOException
      • equals

        public boolean equals​(java.lang.Object o)
        The contract makes us implement equals and hashcode
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Hashcode consistent with equals()
        Overrides:
        hashCode in class java.lang.Object