try {
TypeUDT type = TypeUDT.STREAM;
SocketUDT socket = new SocketUDT(type);
// socket.test();
StringBuilder text = new StringBuilder(1024);
OptionUDT.appendSnapshot(socket, text);
text.append("\t\n");
socket.setOption(OptionUDT.UDT_MSS, 1234);
socket.setOption(OptionUDT.UDT_SNDSYN, false);
socket.setOption(OptionUDT.UDT_RCVSYN, false);
socket.setOption(OptionUDT.UDP_RCVBUF, 12345678);
socket.setOption(OptionUDT.UDP_SNDBUF, 23456789);
socket.setOption(OptionUDT.UDT_MAXBW, 777777777L);
OptionUDT.appendSnapshot(socket, text);
text.append("\t\n");
log.info("options; {}", text);
InetSocketAddress localSocketAddress;
InetSocketAddress remoteSocketAddress;
localSocketAddress = new InetSocketAddress(0);
socket.bind(localSocketAddress);
int code = socket.getErrorCode();
String message = socket.getErrorMessage();
socket.clearError();
log.info("code={} message={}", code, message);
localSocketAddress = socket.getLocalSocketAddress();
log.info("localSocketAddress={}", localSocketAddress);
remoteSocketAddress = socket.getRemoteSocketAddress();
log.info("remoteSocketAddress={}", remoteSocketAddress);
//
log.info("option test");