|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectice.net.ClientSocket
| Constructor Summary | |
ClientSocket(InetAddress inetAddress,
int port)
A wrapper constructor for . |
|
ClientSocket(InetAddress inetAddress,
int port,
boolean stream)
Deprecated. As of 1.5.2, use instead
for UDP transport. |
|
ClientSocket(InetAddress inetAddress,
int port,
InetAddress localInetAddress,
int localPort)
A wrapper constructor for . |
|
ClientSocket(Socket socket)
|
|
ClientSocket(String host,
int port)
A wrapper constructor for . |
|
ClientSocket(String host,
int port,
boolean stream)
Deprecated. As of 1.5.2, use instead
for UDP transport. |
|
ClientSocket(String host,
int port,
InetAddress localInetAddress,
int localPort)
A wrapper constructor for . |
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ClientSocket(InetAddress inetAddress,
int port)
throws IOException,
SecurityException
A wrapper constructor for
. Socket.Socket(InetAddress, int)
Socket.Socket(InetAddress, int)
public ClientSocket(InetAddress inetAddress,
int port,
boolean stream)
throws IOException,
SecurityException
DatagramSocket instead
for UDP transport.
A wrapper constructor for
. Socket.Socket(InetAddress, int, boolean)
Socket.Socket(InetAddress, int, boolean)
public ClientSocket(InetAddress inetAddress,
int port,
InetAddress localInetAddress,
int localPort)
throws IOException,
SecurityException
A wrapper constructor for
. Socket.Socket(InetAddress, int, InetAddress, int)
Socket.Socket(InetAddress, int, InetAddress, int)
public ClientSocket(String host,
int port)
throws IOException,
SecurityException,
UnknownHostException
A wrapper constructor for
. Socket.Socket(String, int)
Socket.Socket(String, int)
public ClientSocket(String host,
int port,
boolean stream)
throws IOException,
SecurityException,
UnknownHostException
DatagramSocket instead
for UDP transport.
A wrapper constructor for
. Socket.Socket(String, int, boolean)
Socket.Socket(String, int, boolean)
public ClientSocket(String host,
int port,
InetAddress localInetAddress,
int localPort)
throws IOException,
SecurityException,
UnknownHostException
A wrapper constructor for
. Socket.Socket(String, int, InetAddress, int)
Socket.Socket(String, int, InetAddress, int)
public ClientSocket(Socket socket)
throws IllegalArgumentException
| Method Detail |
public void close()
throws IOException
A wrapper method for . Socket.close()
close in interface SimpleSocketIOException - if an I/O error occurs when closing the
SimpleSocket.Socket.close()public InetAddress getInetAddress()
A wrapper method for
. Socket.getInetAddress()
getInetAddress in interface SimpleSocketSocket.getInetAddress()
public InputStream getInputStream()
throws IOException
A wrapper method for
. Socket.getInputStream()
getInputStream in interface SimpleSocketIOException - if an I/O error occurs when creating the input stream or
the SimpleSocket is closed.Socket.getInputStream()
public boolean getKeepAlive()
throws SocketException
A wrapper method for . Socket.getKeepAlive()
SocketExceptionSocket.getKeepAlive()public InetAddress getLocalAddress()
A wrapper method for
. Socket.getLocalAddress()
Socket.getLocalAddress()public int getLocalPort()
A wrapper method for . Socket.getLocalPort()
Socket.getLocalPort()
public OutputStream getOutputStream()
throws IOException
A wrapper method for
. Socket.getOutputStream()
getOutputStream in interface SimpleSocketIOException - if an I/O error occurs when creating the output stream or
the SimpleSocket is closed.Socket.getOutputStream()public int getPort()
A wrapper method for . Socket.getPort()
getPort in interface SimpleSocketSocket.getPort()
public int getReceiveBufferSize()
throws SocketException
A wrapper method for
. Socket.getReceiveBufferSize()
SocketExceptionSocket.getReceiveBufferSize()
public int getSendBufferSize()
throws SocketException
A wrapper method for
. Socket.getSendBufferSize()
SocketExceptionSocket.getSendBufferSize()
public int getSoLinger()
throws SocketException
A wrapper method for . Socket.getSoLinger()
SocketExceptionSocket.getSoLinger()
public int getSoTimeout()
throws SocketException
A wrapper method for . Socket.getSoTimeout()
getSoTimeout in interface SimpleSocketSO_TIMEOUT int value.
SocketException - if there is an error in the underlying protocol, such as
a TCP error.Socket.getSoTimeout()
public boolean getTcpNoDelay()
throws SocketException
A wrapper method for . Socket.getTcpNoDelay()
getTcpNoDelay in interface SimpleSockettrue if TCP_NODELAY is enabled,
false if not.
SocketException - if there is an error in the underlying protocol, such as
a TCP error.Socket.getTcpNoDelay()
public void setKeepAlive(boolean on)
throws SocketException
A wrapper method for
. Socket.setKeepAlive(boolean)
SocketExceptionSocket.setKeepAlive(boolean)
public void setReceiveBufferSize(int size)
throws IllegalArgumentException,
SocketException
A wrapper method for
. Socket.setReceiveBufferSize(int)
IllegalArgumentException
SocketExceptionSocket.setReceiveBufferSize(int)
public void setSendBufferSize(int size)
throws IllegalArgumentException,
SocketException
A wrapper method for
. Socket.setSendBufferSize(int)
IllegalArgumentException
SocketExceptionSocket.setSendBufferSize(int)
public void setSoLinger(boolean on,
int linger)
throws IllegalArgumentException,
SocketException
A wrapper method for
. Socket.setSoLinger(boolean, int)
IllegalArgumentException
SocketExceptionSocket.setSoLinger(boolean, int)
public void setSoTimeout(int timeout)
throws IllegalArgumentException,
SocketException
A wrapper method for
. Socket.setSoTimeout(int)
setSoTimeout in interface SimpleSockettimeout - the new timeout in milliseconds.
SocketException - if there is an error in the underlying protocol, such as
a TCP error.
IllegalArgumentException - if the specified timeout is lesser than
0.Socket.setSoTimeout(int)
public void setTcpNoDelay(boolean on)
throws SocketException
A wrapper method for
. Socket.setTcpNoDelay(boolean)
setTcpNoDelay in interface SimpleSocketon - true to enable TCP_NODELAY,
false to disable.
SocketException - if there is an error in the underlying protocol, such as
a TCP error.Socket.setTcpNoDelay(boolean)
public void shutdownInput()
throws IOException
A wrapper method for . Socket.shutdownInput()
IOExceptionSocket.shutdownInput()
public void shutdownOutput()
throws IOException
A wrapper method for
. Socket.shutdownOutput()
IOExceptionSocket.shutdownOutput()public boolean useIp()
SimpleSocketChecks to see if the SimpleSocket needs to use the IP
(Internet Protocol).
useIp in interface SimpleSockettrue if the SimpleSocket needs to
use the IP, false if not.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||