code: public static <V extends VersionedProtocol> V getProxy(Class<V> protocol, InetSocketAddress addr,
  			SocketFactory factory) throws IOException {
  
  		@SuppressWarnings("unchecked")
  		V proxy = (V) Proxy.newProxyInstance(protocol.getClassLoader(), new Class[] { protocol }, new Invoker(addr, factory));
  
  		return proxy;
  	}
docs: Construct a client-side proxy object that implements the named protocol,
  talking to a server at the named address.