2023-01-30 06:12:33 +00:00
|
|
|
//
|
|
|
|
// Created by xajhuang on 2023/1/30.
|
|
|
|
//
|
|
|
|
|
|
|
|
#ifndef VCPE_UUID_H
|
|
|
|
#define VCPE_UUID_H
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
2023-02-02 02:58:49 +00:00
|
|
|
#define UUID_BYTES (16)
|
|
|
|
typedef unsigned char uuid_t[UUID_BYTES];
|
2023-01-30 06:12:33 +00:00
|
|
|
|
|
|
|
#define uuid_generate(out) uuid_generate_random(out)
|
|
|
|
|
|
|
|
void uuid_generate_random(uuid_t out);
|
|
|
|
void uuid_unparse(const uuid_t uuid, char *out);
|
|
|
|
void uuid_copy(uuid_t dst, const uuid_t src);
|
|
|
|
void uuid_parse(const char *in, uuid_t uuid);
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
#endif //VCPE_UUID_H
|