Generators and validators for UUIDs for versions v1, v3, v4 and v5.
Functions
Check if the passed UUID is the nil UUID.
Generates a RFC4122 v1 UUID (time-based).
Validates the UUID v1.
Generate a RFC4122 v3 UUID (MD5 namespace).
Validate that the passed UUID is an RFC4122 v3 UUID.
Validate that the passed UUID is an RFC4122 v4 UUID.
Generate a RFC4122 v5 UUID (SHA-1 namespace).
Validate that the passed UUID is an RFC4122 v5 UUID.
Test a string to see if it is a valid UUID.
Detect RFC version of a UUID.
Interfaces
The options used for generating a v1 UUID in generate.
- clockseq: number
A 14-bit value used to avoid duplicates that could arise when the clock is set backwards in time or if the node ID changes (0 - 16383).
- msecs: number
The number of milliseconds since the Unix epoch (January 1, 1970).
- node: number[]
An array of 6 bytes that represents a 48-bit IEEE 802 MAC address.
- nsecs: number
The number of nanoseconds to add to
V1Options.msecs(0 - 10,000). - random: number[]
An array of 16 random bytes (0 - 255).
- rng: () => number[]
A function that returns an array of 16 random bytes (0 - 255). Alternative to
V1Options.random.
Namespaces
Variables
Name string is a fully-qualified domain name.
Name string is an ISO OID.
Name string is a URL.
Name string is an X.500 DN (in DER or a text output format).
The nil UUID is special form of UUID that is specified to have all 128 bits set to zero.
Variables
Name string is a fully-qualified domain name.
Name string is an ISO OID.
Name string is a URL.
Name string is an X.500 DN (in DER or a text output format).
Functions
Interfaces
The options used for generating a v1 UUID in generate.
- clockseq: number
A 14-bit value used to avoid duplicates that could arise when the clock is set backwards in time or if the node ID changes (0 - 16383).
- msecs: number
The number of milliseconds since the Unix epoch (January 1, 1970).
- node: number[]
An array of 6 bytes that represents a 48-bit IEEE 802 MAC address.
- nsecs: number
The number of nanoseconds to add to
V1Options.msecs(0 - 10,000). - random: number[]
An array of 16 random bytes (0 - 255).
- rng: () => number[]
A function that returns an array of 16 random bytes (0 - 255). Alternative to
V1Options.random.