Universally Unique Identifier - Variants and Versions

Variants and Versions

The variant indicates the layout of the UUID. The UUID specification covers one particular variant. Other variants are reserved or exist for backward compatibility reasons (e.g. for values assigned before the UUID specification was produced). An example of a UUID that is a different variant is the nil UUID, which is a UUID that has all 128 bits set to zero.

In the canonical representation, xxxxxxxx-xxxx-Mxxx-Nxxx-xxxxxxxxxxxx, the most significant bits of N indicates the variant (depending on the variant; one, two or three bits are used). The variant covered by the UUID specification is indicated by the two most significant bits of N being 1 0 (i.e. the hexadecimal N will always be 8, 9, A, or B).

In the variant covered by the UUID specification, there are five versions. For this variant, the four bits of M indicates the UUID version (i.e. the hexadecimal M will either be 1, 2, 3, 4, or 5).

Read more about this topic:  Universally Unique Identifier

Famous quotes containing the words variants and/or versions:

    Nationalist pride, like other variants of pride, can be a substitute for self-respect.
    Eric Hoffer (1902–1983)

    The assumption must be that those who can see value only in tradition, or versions of it, deny man’s ability to adapt to changing circumstances.
    Stephen Bayley (b. 1951)