Package java.net
Class Socket
- java.lang.Object
-
- java.net.Socket
-
public class Socket extends Object
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSocket()Socket(String var0, int var1)Socket(String var0, int var1, InetAddress var2, int var3)Socket(InetAddress var0, int var1)Socket(InetAddress var0, int var1, InetAddress var2, int var3)protectedSocket(SocketImpl var0)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()InetAddressgetInetAddress()InputStreamgetInputStream()booleangetKeepAlive()InetAddressgetLocalAddress()intgetLocalPort()OutputStreamgetOutputStream()intgetPort()intgetReceiveBufferSize()intgetSendBufferSize()intgetSoLinger()intgetSoTimeout()booleangetTcpNoDelay()voidsetKeepAlive(boolean var0)voidsetReceiveBufferSize(int var0)voidsetSendBufferSize(int var0)static voidsetSocketImplFactory(SocketImplFactory var0)voidsetSoLinger(boolean var0, int var1)voidsetSoTimeout(int var0)voidsetTcpNoDelay(boolean var0)voidshutdownInput()voidshutdownOutput()StringtoString()
-
-
-
Constructor Detail
-
Socket
protected Socket()
-
Socket
public Socket(String var0, int var1) throws UnknownHostException, IOException
- Throws:
UnknownHostExceptionIOException
-
Socket
public Socket(String var0, int var1, InetAddress var2, int var3) throws IOException
- Throws:
IOException
-
Socket
public Socket(InetAddress var0, int var1) throws IOException
- Throws:
IOException
-
Socket
public Socket(InetAddress var0, int var1, InetAddress var2, int var3) throws IOException
- Throws:
IOException
-
Socket
protected Socket(SocketImpl var0) throws SocketException
- Throws:
SocketException
-
-
Method Detail
-
close
public void close() throws IOException- Throws:
IOException
-
getInetAddress
public InetAddress getInetAddress()
-
getInputStream
public InputStream getInputStream() throws IOException
- Throws:
IOException
-
getKeepAlive
public boolean getKeepAlive() throws SocketException- Throws:
SocketException
-
getLocalAddress
public InetAddress getLocalAddress()
-
getLocalPort
public int getLocalPort()
-
getOutputStream
public OutputStream getOutputStream() throws IOException
- Throws:
IOException
-
getPort
public int getPort()
-
getSoLinger
public int getSoLinger() throws SocketException- Throws:
SocketException
-
getReceiveBufferSize
public int getReceiveBufferSize() throws SocketException- Throws:
SocketException
-
getSendBufferSize
public int getSendBufferSize() throws SocketException- Throws:
SocketException
-
getSoTimeout
public int getSoTimeout() throws SocketException- Throws:
SocketException
-
getTcpNoDelay
public boolean getTcpNoDelay() throws SocketException- Throws:
SocketException
-
setKeepAlive
public void setKeepAlive(boolean var0) throws SocketException- Throws:
SocketException
-
setSocketImplFactory
public static void setSocketImplFactory(SocketImplFactory var0) throws IOException
- Throws:
IOException
-
setSendBufferSize
public void setSendBufferSize(int var0) throws SocketException- Throws:
SocketException
-
setReceiveBufferSize
public void setReceiveBufferSize(int var0) throws SocketException- Throws:
SocketException
-
setSoLinger
public void setSoLinger(boolean var0, int var1) throws SocketException- Throws:
SocketException
-
setSoTimeout
public void setSoTimeout(int var0) throws SocketException- Throws:
SocketException
-
setTcpNoDelay
public void setTcpNoDelay(boolean var0) throws SocketException- Throws:
SocketException
-
shutdownInput
public void shutdownInput() throws IOException- Throws:
IOException
-
shutdownOutput
public void shutdownOutput() throws IOException- Throws:
IOException
-
-