List of usage examples for java.net ServerSocket hashCode
@HotSpotIntrinsicCandidate public native int hashCode();
From source file:Main.java
/** * Renders the details of a server socket in the returned string * @param socket The server socket to render * @return the details of the server socket as a string *//*from www . j a v a2s .com*/ public static String render(ServerSocket socket) { if (socket == null) return "NULL"; StringBuilder b = new StringBuilder("\nSocket ["); b.append("\n\tLocalPort:").append(socket.getLocalPort()); b.append("\n\tLocalAddress:").append(socket.getInetAddress()); b.append("\n\tLocalSocketAddress:").append(socket.getLocalSocketAddress()); b.append("\n\tChannel:").append(socket.getChannel()); b.append("\n\tHashCode:").append(socket.hashCode()); b.append("\n]"); return b.toString(); }