| 1 |
#ifndef AWS_COMMON_UUID_H |
| 2 |
#define AWS_COMMON_UUID_H |
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
#include <aws/common/common.h> |
| 9 |
|
| 10 |
AWS_PUSH_SANE_WARNING_LEVEL |
| 11 |
|
| 12 |
struct aws_byte_cursor; |
| 13 |
struct aws_byte_buf; |
| 14 |
|
| 15 |
struct aws_uuid { |
| 16 |
uint8_t uuid_data[16]; |
| 17 |
}; |
| 18 |
|
| 19 |
|
| 20 |
enum { AWS_UUID_STR_LEN = 37 }; |
| 21 |
|
| 22 |
enum { AWS_UUID_STR_COMPACT_LEN = 33 }; |
| 23 |
|
| 24 |
AWS_EXTERN_C_BEGIN |
| 25 |
|
| 26 |
AWS_COMMON_API int aws_uuid_init(struct aws_uuid *uuid); |
| 27 |
AWS_COMMON_API int aws_uuid_init_from_str(struct aws_uuid *uuid, const struct aws_byte_cursor *uuid_str); |
| 28 |
AWS_COMMON_API int aws_uuid_to_str(const struct aws_uuid *uuid, struct aws_byte_buf *output); |
| 29 |
AWS_COMMON_API int aws_uuid_to_str_compact(const struct aws_uuid *uuid, struct aws_byte_buf *output); |
| 30 |
AWS_COMMON_API bool aws_uuid_equals(const struct aws_uuid *a, const struct aws_uuid *b); |
| 31 |
|
| 32 |
AWS_EXTERN_C_END |
| 33 |
AWS_POP_SANE_WARNING_LEVEL |
| 34 |
|
| 35 |
#endif |