suspend fun connect(remote: SocketAddress): CoroutineSocketChannel
(source)
Connect this channel.
remote
- The remote address to which this channel is to be connected.
ClosedChannelException
- If the channel is closed.
AsynchronousCloseException
- If another thread closes this channel while the connect operation is in
progress.
ClosedByInterruptException
- If another thread interrupts the current thread while the connect operation is
in progress, thereby closing the channel and setting the current thread's interrupt status.
IOException
- If some other I/O error occurs.
Return
This channel.