Interface AFSomeSocket
- All Superinterfaces:
AFSomeSocketThing, AutoCloseable, Closeable, FileDescriptorAccess
- All Known Implementing Classes:
AFDatagramChannel, AFDatagramSocket, AFSocket, AFSocketChannel, AFUNIXDatagramChannel, AFUNIXDatagramSocket, AFUNIXSocket, AFUNIXSocketChannel
Marker interface that combines junixsocket-based
SocketChannels, Sockets,
DatagramChannels and DatagramSockets.- Author:
- Christian Kohlschütter
- See Also:
-
Method Summary
Modifier and TypeMethodDescription@Nullable SocketAddressReturns the socket's remote socket address, ornullif unavailable/not connected, or if there was a problem retrieving it.Methods inherited from interface AFSomeSocketThing
getLocalSocketAddress, setShutdownOnCloseModifier and TypeMethodDescription@Nullable SocketAddressReturns the socket's local socket address, ornullif unavailable or if there was a problem retrieving it.voidsetShutdownOnClose(boolean enabled) Configures whether the socket should be shutdown uponCloseable.close(), which is the default.Methods inherited from interface FileDescriptorAccess
getFileDescriptor
-
Method Details
-
getRemoteSocketAddress
@Nullable SocketAddress getRemoteSocketAddress()Returns the socket's remote socket address, ornullif unavailable/not connected, or if there was a problem retrieving it.- Returns:
- The remote socket address, or
null.
-