Creates a new UUID instance.
Use UUID.v4() or UUID.v7() to generate random new UUIDs.
The UUID string.
Whether to validate the UUID string. Defaults to true.
The version of the UUID. If not provided, it is inferred from the UUID string.
Private Readonly _rawReadonly versionThe version of the UUID.
Implementation of $SerializeForCollection for TableCodec
Implementation of $SerializeForTable for TableCodec
Compares this UUID to another UUID.
The other UUID can be a UUID instance or a string.
A UUID is considered equal to another UUID if their lowercase string representations are equal.
The UUID to compare to.
true if the UUIDs are equal, false otherwise.
Static [$Implementation of $DeserializeForCollection for TableCodec
Static [$Implementation of $DeserializeForTable for TableCodec
Static v1Static v4Static v6Static v7
Represents a UUID that can be used as an _id in the DataAPI.
Provides methods for creating v4 and v7 UUIDs, and for parsing timestamps from v7 UUIDs.
Example
Example
See
ObjectId