B
Bob Miller
Hello.
I need to convert some small Java source to C#.
Can anybody help me?
============================================================================================
private SocketChannel getNBConnSock(SocketAddress local, SocketAddress
remote, Selector sel) throws Exception {
SocketChannel sock = SocketChannel.open();
sock.socket().setReuseAddress(true);
if (local != null) sock.socket().bind(local);
sock.configureBlocking(false);
SelectionKey sockKey = sock.register(sel, SelectionKey.OP_CONNECT);
sockKey.attach(this);
sock.connect(remote);
return sock;
}
============================================================================================
Thank you
I need to convert some small Java source to C#.
Can anybody help me?
============================================================================================
private SocketChannel getNBConnSock(SocketAddress local, SocketAddress
remote, Selector sel) throws Exception {
SocketChannel sock = SocketChannel.open();
sock.socket().setReuseAddress(true);
if (local != null) sock.socket().bind(local);
sock.configureBlocking(false);
SelectionKey sockKey = sock.register(sel, SelectionKey.OP_CONNECT);
sockKey.attach(this);
sock.connect(remote);
return sock;
}
============================================================================================
Thank you