
KMem introduces a wrapper around it that makes the signature more familiar (like Java’s System.arraycopy). Kotlin 1.3 introduces an pyInto extension, but the signature is a bit confusing. Implementation(":kmem-android:$kmemVersion") Requires Gradle 7.1.1 ( JVM 8~13) for building and Kotlin >=1.5.20 for running:ī val kmemVersion = "2.2.0"
nextAlignedTo, prevAlignedTo, isAlignedTo, nextPowerOfTwo, prevPowerOfTwo, isPowerOfTwo.
clamp, convertRange, convertRangeClamped. mask, extract, extractSigned, insert, hasFlags. countLeadingZeros, countTrailingZeros, countLeadingOnes, countTrailingOnes. ByteArrayReader, ByteArrayReaderLE, ByteArrayReaderBE. ByteArrayBuilder, ByteArrayBuilderLE, ByteArrayBuilderBE.
MemBuffer, DataBuffer, Int8Buffer, Int16Buffer, Int32Buffer, Float32Buffer, Float64Buffer. UByteArrayInt and FloatArrayFromIntArray.