public class TcpSocket extends Socket
| Modifier and Type | Field and Description |
|---|---|
static boolean |
socketsInitialised |
| Constructor and Description |
|---|
TcpSocket(SocketDescriptor sock) |
TcpSocket(SocketDescriptor sock,
boolean close) |
TcpSocket(String host,
int port) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
static boolean |
enableNagles(SocketDescriptor sock,
boolean enable) |
protected void |
finalize() |
static int |
findFreeTcpPort() |
int |
getMyPort() |
String |
getPeerAddress() |
String |
getPeerEndpoint() |
String |
getPeerName() |
int |
getPeerPort() |
int |
getSockPort() |
static void |
initSockets() |
boolean |
isConnected() |
static boolean |
isSocket(Socket sock) |
boolean |
sameMachine() |
void |
shutdown() |
getFd, inStream, isShutdown, outStream, requiresQuery, setRequiresQuerypublic TcpSocket(SocketDescriptor sock, boolean close)
public TcpSocket(SocketDescriptor sock)
public static void initSockets()
protected void finalize()
throws Exception
public String getPeerAddress()
getPeerAddress in class Socketpublic String getPeerName()
getPeerName in class Socketpublic int getPeerPort()
getPeerPort in class Socketpublic String getPeerEndpoint()
getPeerEndpoint in class Socketpublic boolean sameMachine()
throws Exception
sameMachine in class SocketExceptionpublic void shutdown()
throws Exception
public void close()
throws IOException
close in class SocketIOExceptionpublic static boolean enableNagles(SocketDescriptor sock, boolean enable)
public static boolean isSocket(Socket sock)
public boolean isConnected()
public int getSockPort()
public static int findFreeTcpPort()
Copyright © 2019. All rights reserved.