Distributed Publish & Subscribe for IoT
UUID

Create and compare UUIDs. More...

Data Structures

struct  _DPS_UUID
 Type definition for a UUID. More...
 

Typedefs

typedef struct _DPS_UUID DPS_UUID
 Type definition for a UUID.
 

Functions

void DPS_GenerateUUID (DPS_UUID *uuid)
 Non secure generation of a random UUID. More...
 
DPS_Status DPS_InitUUID (void)
 One time initialization. More...
 
int DPS_UUIDCompare (const DPS_UUID *a, const DPS_UUID *b)
 Numerical comparison of two UUIDs. More...
 
const char * DPS_UUIDToString (const DPS_UUID *uuid)
 Return a string representation of a UUID. More...
 

Detailed Description

Create and compare UUIDs.

Function Documentation

◆ DPS_GenerateUUID()

void DPS_GenerateUUID ( DPS_UUID uuid)

Non secure generation of a random UUID.

Parameters
uuidThe generated UUID.

◆ DPS_InitUUID()

DPS_Status DPS_InitUUID ( void  )

One time initialization.

Returns
DPS_OK if initialization succeeds, an error otherwise

◆ DPS_UUIDCompare()

int DPS_UUIDCompare ( const DPS_UUID a,
const DPS_UUID b 
)

Numerical comparison of two UUIDs.

Parameters
aOne of the UUIDs to compare
bThe other UUID to compare
Returns
  • <0 if a less than b
  • 0 if a equal to b
  • >0 if a greater than b

◆ DPS_UUIDToString()

const char* DPS_UUIDToString ( const DPS_UUID uuid)

Return a string representation of a UUID.

Note
This function uses a static string and is non-reentrant.
Parameters
uuidThe UUID
Returns
The string representation