write

infix fun File.write(block: BufferedWriter.() -> Unit)

Writes content to a file using a buffered writer.

Receiver

The file to write to.

Parameters

block

A lambda function containing the writing logic.