Closeable
, AutoCloseable
SSLSocket
Constructors
Creates an unconnected Socket.
Creates a stream socket and connects it to the specified port number on the named host.
Deprecated, for removal: This API element is subject to removal in a future version.Creates a socket and connects it to the specified remote host on the specified remote port.
Creates a stream socket and connects it to the specified port number at the specified IP address.
Deprecated, for removal: This API element is subject to removal in a future version.Creates a socket and connects it to the specified remote address on the specified remote port.
Creates an unconnected socket, specifying the type of proxy, if any, that should be used regardless of any other settings.
protected
Creates an unconnected Socket with a user-specified SocketImpl.
void
Binds the socket to a local address.
void
void
Connects this socket to the server.
void
Connects this socket to the server with a specified timeout value.
Returns the unique
SocketChannel
object associated with this socket, if any.
Returns the address to which the socket is connected.
Returns an input stream for this socket.
boolean
Gets the local address to which the socket is bound.
int
Returns the local port number to which this socket is bound.
Returns the address of the endpoint this socket is bound to.
boolean
<T> T
Returns the value of a socket option.
Returns an output stream for this socket.
int
Returns the remote port number to which this socket is connected.
int
Gets the value of the
SO_RCVBUF
option for this
Socket
, that is the buffer size used by the platform for input on this
Socket
.
Returns the address of the endpoint this socket is connected to, or null
if it is unconnected.
boolean
int
Get value of the
SO_SNDBUF
option for this
Socket
, that is the buffer size used by the platform for output on this
Socket
.
int
int
Returns setting for
SO_TIMEOUT
. 0 returns implies that the option is disabled (i.e., timeout of infinity).
boolean
int
Gets traffic class or type-of-service in the IP header for packets sent from this Socket
boolean
Returns the binding state of the socket.
boolean
Returns the closed state of the socket.
boolean
Returns the connection state of the socket.
boolean
Returns whether the read-half of the socket connection is closed.
boolean
Returns whether the write-half of the socket connection is closed.
void
Send one byte of urgent data on the socket.
void
void
Enable/disable
SO_OOBINLINE
(receipt of TCP urgent data) By default, this option is disabled and TCP urgent data received on a socket is silently discarded.
Sets the value of a socket option.
void
Sets performance preferences for this socket.
void
Sets the
SO_RCVBUF
option to the specified value for this
Socket
.
void
void
Sets the
SO_SNDBUF
option to the specified value for this
Socket
.
static void
void
Enable/disable
SO_LINGER
with the specified linger time in seconds.
void
Enable/disable
SO_TIMEOUT
with the specified timeout, in milliseconds.
void
Enable/disable
TCP_NODELAY
(disable/enable Nagle's algorithm).
void
Sets traffic class or type-of-service octet in the IP header for packets sent from this Socket.
void
Places the input stream for this socket at "end of stream".
void
Disables the output stream for this socket.
Returns a set of the socket options supported by this socket.
Converts this socket to a String
.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4