encodeIntoByteArray
Encodes bytes from the specified source array or its subrange and writes resulting symbols into the destination array. Returns the number of symbols written.
If the size of the source array or its subrange is not an integral multiple of 3, the result is padded with '='
to an integral multiple of 4 symbols.
Since Kotlin
1.8Return
the number of symbols written into destination array.
Parameters
the array to encode bytes from.
the array to write symbols into.
the starting index in the destination array to write symbols to, 0 by default.
the beginning (inclusive) of the subrange to encode, 0 by default.
the end (exclusive) of the subrange to encode, size of the source array by default.
Throws
when the resulting symbols don't fit into the destination array starting at the specified destinationOffset, or when that index is out of the destination array indices range.
when startIndex > endIndex
.