if (broadcast != null) socket.setBroadcast(broadcast.booleanValue());
if (receiveBufferSize != null) socket.setReceiveBufferSize(receiveBufferSize.intValue());
if (sendBufferSize != null) socket.setSendBufferSize(sendBufferSize.intValue());
if (reuseAddress != null) socket.setReuseAddress(reuseAddress.booleanValue());
if (trafficClass != null) socket.setTrafficClass(trafficClass.intValue());
socket.bind(address);
//noinspection unchecked
final IoHandler<? super UdpChannel> handler = handlerFactory.createHandler();
final NioUdpSocketChannelImpl udpSocketChannel = createChannel(datagramChannel, handler);
final FutureUdpChannel futureUdpChannel = new FutureUdpChannel(udpSocketChannel, datagramChannel);
boundChannels.add(udpSocketChannel);