ktor-io / io.ktor.utils.io.streams / java.io.OutputStream / writePacket

writePacket

fun OutputStream.writePacket(builder: BytePacketBuilder.() -> Unit): Unit

Write the whole packet to the stream once it is built via builder lambda

fun OutputStream.writePacket(packet: ByteReadPacket): Unit

Write the whole packet to the stream