nix32Main.platform.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of uuid Show documentation
Show all versions of uuid Show documentation
A Kotlin multiplatform implementation of a v4 RFC4122 UUID
package com.benasher44.uuid
import platform.posix.read
internal actual fun getRandomUuidBytes(): ByteArray {
return bytesWithURandomFd { fd, bytePtr ->
read(fd, bytePtr, UUID_BYTES.toUInt())
}
}