DL Logo

ASUUID Definitions

ASUUIDMaxStringLen

Header: ASExpT.h:4001

Description

A constant for the maximum string length of a unique identifier (UUID).

Related Methods

Syntax

#define ASUUIDMaxStringLen 40

ASUUID Structures

ASUUID

Header: ASExpT.h:3981

Description

A structure representing a universal unique identifier (UUID) for the current user or the current session.

Syntax

struct ASUUID {
ASUns32 timeLow;
Timestamp low field.
ASUns16 timeMid;
Timestamp middle field.
ASUns16 timeHiAndVersion;
Timestamp middle field multiplexed with the version number.
ASUns8 clockSeqHiAndReserved;
High field of the clock sequence multiplexed with the variant.
ASUns8 clockSeqLow;
Low field of the clock sequence.
ASUns8 node [6];
The spatially unique node identifier.
} ASUUID;

Used By

ASUUID Functions

ASUUIDFromCString

Header: ASProcs.h:2215

Description

Parses a C string, such as one generated by ASUUIDToCString(), into a unique identifier (UUID).

Syntax

ASBool ASUUIDFromCString(ASUUID *dst, const char *str);

Parameters

dst
(Filled by the method) The UUID created from the string.
str
A NULL-terminated string from which to generate the UUID, in the following form: f81d4fae-7dec-11d0-a765-00a0c91e6bf6.

Returns

true if the UUID is successfully created, false otherwise.

ASUUIDGenFromHash

Header: ASProcs.h:2198

Description

Generates a unique identifier (UUID) from a hash value.

Syntax

ASBool ASUUIDGenFromHash(ASUUID *dst, ASUns8 hash [16]);

Parameters

dst
(Filled by the method) The UUID created from the hash.
hash
A hash value, such as MD5.

Returns

true if the UUID is successfully created, false otherwise.

ASUUIDGenFromName

Header: ASProcs.h:2182

Description

Generates a universal unique identifier (UUID) for a block of data (a name) in a context (a namespace).

Syntax

ASBool ASUUIDGenFromName(ASUUID *dst, const ASUUID *ns, void *name, ASByteCount bytes);

Parameters

dst
(Filled by the method) The UUID created from the name.
ns
A namespace or context meaningful to the client.
name
A pointer to an arbitrary block of data to be identified by the UUID.
bytes
The number of bytes in name.

Returns

true if the UUID is successfully created, false otherwise.

ASUUIDGenUnique

Header: ASProcs.h:2162

Description

Generates a unique identifier (UUID).

Syntax

ASBool ASUUIDGenUnique(ASUUID *dst);

Parameters

dst
(Filled by the method) The UUID created from the hash.

Returns

true if the UUID is successfully created, false otherwise.

ASUUIDToCString

Header: ASProcs.h:2233

Description

Generates a NULL-terminated C string from the unique identifier (UUID) for a user or session.

Syntax

void ASUUIDToCString(char *dst, const ASUUID *src);

Parameters

dst
(Filled by the method) A NULL-terminated string from which to generate the UUID, in the following form: f81d4fae-7dec-11d0-a765-00a0c91e6bf6. The string must be at least the length specified by ASUUIDMaxStringLen().
src
The UUID from which to generate the string.