Closed 05nelsonm closed 1 year ago
Would be nice to be able to specify an offset and length when encoding
offset
length
@Throws(IllegalArgumentException::class, IndexOutOfBoundsException::class) fun ByteArray.encodeToString(offset: Int, len: Int, encoder: Encoder<*>): String { // ... }
Usage
val bytes = Random.Default.nextBytes(500) val partialEncoding = bytes.encodeToString(50, 100, Base16())
If users desire this, they can utilize Encoder.newEncoderFeed
Encoder.newEncoderFeed
Would be nice to be able to specify an
offset
andlength
when encodingUsage