equals
Checks whether this uuid is equal to the specified other object.
import kotlin.uuid.*
fun main(args: Array<String>) {
//sampleStart
val uuid1 = Uuid.fromULongs(0x550E8400E29B41D4uL, 0xA716446655440000uL)
val uuid2 = Uuid.parse("550e8400-e29b-41d4-a716-446655440000")
val uuid3 = Uuid.parse("550e8400-e29b-41d4-a716-446655440001") // the last bit is one
println(uuid1 == uuid2) // true
println(uuid1 == uuid3) // false
//sampleEnd
}
Parameters
other
- The object to compare with this uuid.
Return true
if other is an instance of Uuid, and consists of the same sequence
of bits as this uuid; false
otherwise.