end
Half-closes the socket. i.e., it sends a FIN packet. It is possible the server will still send some data.
See writable.end() for further details.
Since
v0.1.90
Return
The socket itself.
Parameters
callback
Optional callback for when the socket is finished.
Half-closes the socket, with one final chunk of data.
Since
v0.1.90
Return
The socket itself.
Parameters
callback
Optional callback for when the socket is finished.
See also
{@link Socket.end} for full details.
fun end(str: Uint8Array<*>, encoding: BufferEncoding = definedExternally, cb: () -> Unit = definedExternally)(source)
open override fun end(str: String, encoding: BufferEncoding = definedExternally, cb: () -> Unit = definedExternally)(source)
Half-closes the socket, with one final chunk of data.
Since
v0.1.90
Return
The socket itself.
Parameters
encoding='utf8' Only used when data is string.
callback
Optional callback for when the socket is finished.
See also
{@link Socket.end} for full details.