SokDoc

sok / Sok.Socket.TCP / TCPClientSocket / <init>

<init>

TCPClientSocket(channel: SocketChannel, selectorPool: SelectorPool)

Platform and version requirements: JVM

Helper contrutor that simply get the less busy selector from the pool then use the “standard” constructor

Parameters

channel - NIO channel

selectorPool - Selector pool to useTCPClientSocket(channel: SocketChannel, selector: Selector)

Platform and version requirements: JVM

Wrap a NIO channel with a Sok client socket class

Parameters

channel - NIO channel

selector - Selector used to track the NIO channelTCPClientSocket(socket: dynamic)

Platform and version requirements: JS

Wrap a Node.js socket with Sok Client socket class

Parameters

socket - Node.js socket class