writeString

open fun writeString(    value: String,     encoding: StringEncoding = defaultStringEncoding,     startIndex: Int = 0,     size: Int = -1,     byteOrder: ByteOrder = defaultByteOrder,     needTerminator: Boolean = true): Int

Writes string into the stream.

Return

number of code points written to the stream without terminate zero character.

Parameters

value

the string for write

encoding

of target string

startIndex

of code point in source string

size

maximum number of code points for write or zero/negative value to autodetection

byteOrder

for UTF-16 and UTF-32 encoding

needTerminator

if true zero code point will be added into the end of the target string