Diego
ByteArray
KotlinByteArray
NSData
private fun ByteArray.toNSData(): NSData = memScoped { return NSData.create( bytes = toCValues().getPointer(this), length = size.toUInt() ) } private fun NSData.toByteArray(): ByteArray = memScoped { val size = length.toInt() val nsData = ByteArray(size) memcpy(nsData.refTo(0), bytes, size.toUInt()) return nsData }
ribesg
Jonas Bark
A modern programming language that makes developers happier.