对于以下程序代码:A.cket socket=new Socket(); //第1行B.cketAddress remoteAddr1=new InetSocketAdd
It would be nice if one could check to see if reverse DNS would be required before calling getHostName(). For instance HTTP logging code could do something like this: InetSocketAddress a = (InetSocketAddress)socket.getLocalSocketAddress(); if (a.isReverseResolved()) { out.print(a.getHos...