struct

UUID

Inherits Comparable < Struct < Value < Object

monkey patch UUID to introduce a new class method onto UUID

Constructors

from_u128(u128 : UInt128, version : UUID::Version | Nil = nil, variant : UUID::Variant | Nil = nil) : UUID

Returns a UUID from a given u128 NOTE: The the most significant byte of the u128 is the most significant byte (left-most byte) of the UUID, and the least significant byte of the u128 is the least significant byte (right-most byte) of the UUID.

Source
from_u128_inverted(u128 : UInt128, version : UUID::Version | Nil = nil, variant : UUID::Variant | Nil = nil) : UUID

Returns a UUID from a given u128 NOTE: This encoding is called "inverted" because the the most significant byte of the u128 is the least significant byte (right-most byte) of the UUID and the least significant byte of the u128 is the most significant byte (left-most byte) of the UUID.

Source

Instance methods

to_u128
Source
to_u128_inverted
Source