public class DatagramChannelWithTimeouts extends DatagramChannel
| Modifier and Type | Field and Description |
|---|---|
protected DatagramChannel |
channel |
protected SelectionKey |
channelKey |
protected Selector |
selector |
| Modifier | Constructor and Description |
|---|---|
protected |
DatagramChannelWithTimeouts() |
open, read, validOps, writeblockingLock, configureBlocking, implCloseChannel, isBlocking, isRegistered, keyFor, provider, registerregisterbegin, close, end, isOpenclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcloseprotected DatagramChannel channel
protected Selector selector
protected SelectionKey channelKey
protected DatagramChannelWithTimeouts()
throws IOException
IOExceptionpublic static DatagramChannel open() throws IOException
IOExceptionpublic DatagramChannel bind(SocketAddress socketAddress) throws IOException
bind in interface NetworkChannelbind in class DatagramChannelIOExceptionpublic SocketAddress getLocalAddress() throws IOException
getLocalAddress in interface NetworkChannelgetLocalAddress in class DatagramChannelIOExceptionpublic <T> DatagramChannel setOption(SocketOption<T> socketOption, T t) throws IOException
setOption in interface NetworkChannelsetOption in class DatagramChannelIOExceptionpublic <T> T getOption(SocketOption<T> socketOption) throws IOException
IOExceptionpublic Set<SocketOption<?>> supportedOptions()
public int read(ByteBuffer dst) throws IOException
read in interface ReadableByteChannelread in class DatagramChannelIOExceptionpublic long read(ByteBuffer[] dsts, int offset, int length) throws IOException
read in interface ScatteringByteChannelread in class DatagramChannelIOExceptionpublic int write(ByteBuffer src) throws IOException
write in interface WritableByteChannelwrite in class DatagramChannelIOExceptionpublic long write(ByteBuffer[] srcs, int offset, int length) throws IOException
write in interface GatheringByteChannelwrite in class DatagramChannelIOExceptionprotected void implCloseSelectableChannel()
throws IOException
implCloseSelectableChannel in class AbstractSelectableChannelIOExceptionprotected void implConfigureBlocking(boolean block)
throws IOException
implConfigureBlocking in class AbstractSelectableChannelIOExceptionpublic boolean isConnected()
isConnected in class DatagramChannelpublic void setReadTimeout(int t)
public DatagramSocket socket()
socket in class DatagramChannelpublic DatagramChannel disconnect() throws IOException
disconnect in class DatagramChannelIOExceptionpublic SocketAddress receive(ByteBuffer dst) throws IOException
receive in class DatagramChannelIOExceptionpublic int send(ByteBuffer src, SocketAddress target) throws IOException
send in class DatagramChannelIOExceptionpublic DatagramChannel connect(SocketAddress remote) throws IOException
connect in class DatagramChannelIOExceptionpublic SocketAddress getRemoteAddress() throws IOException
getRemoteAddress in class DatagramChannelIOExceptionpublic MembershipKey join(InetAddress inetAddress, NetworkInterface networkInterface) throws IOException
IOExceptionpublic MembershipKey join(InetAddress inetAddress, NetworkInterface networkInterface, InetAddress inetAddress1) throws IOException
IOExceptionCopyright © 2016. All rights reserved.