Products Support Documentation Download
Universally Unique Identifier (UUID) API
Collaboration diagram for Universally Unique Identifier (UUID) API:

Functions

void rdm_uuidCreate (RDM_UUID_T *uuid)
 
RDM_RETCODE rdm_uuidFromString (const RDM_TCHAR_T *str, RDM_UUID_T *uuid)
 
size_t rdm_uuidStrLen (const RDM_UUID_T *uuid, RDM_BOOL_T braces)
 
RDM_RETCODE rdm_uuidToString (const RDM_UUID_T *uuid, RDM_TCHAR_T *str, size_t len, RDM_BOOL_T braces)
 

Detailed Description

The RDM uuid datatype API. The functions here are located in RDM Base Functionality. Linker option:

    -lrdmbase

The UUID/GUID types represent 128-bit unique identifiers. The implementation of UUID/GUID is represented by the RFC 4122 standard

Function Documentation

◆ rdm_uuidCreate()

void rdm_uuidCreate ( RDM_UUID_T uuid)

#include <rdmuuidapi.h>

Create a Universally Unique Identifier (UUID)

This function is able to create a universally unique identifier with a very high probability.

See also
rdm_uuidToString
rdm_uuidFromString
Parameters
[out]uuidThe Universally Unique Identifier to be creasted

◆ rdm_uuidFromString()

RDM_RETCODE rdm_uuidFromString ( const RDM_TCHAR_T str,
RDM_UUID_T uuid 
)

#include <rdmuuidapi.h>

Convert a string to a Universally Unique Identifier (UUID)

Convert a string to a Universally Unique Identifier (UUID).

Return values
sOKAYNormal, successful return.
ePSP_INVUUIDInvalid UUID in the PSP library.
See also
rdm_uuidToString
rdm_uuidCreate
Parameters
[in]strThe UUID in string form that is to be converted
[out]uuidThe converted UUID

◆ rdm_uuidStrLen()

size_t rdm_uuidStrLen ( const RDM_UUID_T uuid,
RDM_BOOL_T  braces 
)

#include <rdmuuidapi.h>

Get the string length of a Universally Unique Identifier (UUID)

Get the string length of a Universally Unique Identifier if it were to be converted to a string.

Returns
The string length, if converted to a string
Parameters
[in]uuidThe UUID we want the string length off if converted to a string
[in]bracesWhether the converted string should include braces

◆ rdm_uuidToString()

RDM_RETCODE rdm_uuidToString ( const RDM_UUID_T uuid,
RDM_TCHAR_T str,
size_t  len,
RDM_BOOL_T  braces 
)

#include <rdmuuidapi.h>

Convert a Universally Unique Identifier (UUID) to a string

Convert a Universally Unique Identifier (UUID) to a string. The string buffer provided should be big enough to hold at least 36 characters, plus the optional braces, and a null terminator.

Return values
sOKAYNormal, successful return.
sTRUNCATEResult is truncated.
See also
rdm_uuidStrLen
rdm_uuidFromString
rdm_uuidCreate
Parameters
[in]uuidThe UUID that is to be converted
[out]strThe string buffer for the converted UUID
[in]lenThe lengt of the provided string buffer measured in number of characters
[in]bracesWhether the converted string should include braces