#include <stdint.h>
#include <string.h>
#include "lib.h"
#include "list.h"
Go to the source code of this file.
◆ DefList()
Convert a UUID into a string.
In order to actually get the string, you have to do:
INFO: The caller does not have to free the memory! ;)
- Parameters
-
| uuid | the UUID that you want a string for |
- Returns
- a UUID_Str representing that UUID
◆ from_hex()
| uint64_t from_hex |
( |
Str | str, |
|
|
size_t | max_len ) |
Converts a wire format string into a 64-bit integer.
- Parameters
-
| str | the wire format string to convert |
| max_len | the amount of characters to read from the string |
- Returns
- a 64-bit integer with the value of the wire format
◆ ListHexByte_print()
| void ListHexByte_print |
( |
ListHexByte | list, |
|
|
char | end ) |
Print a list of hex bytes.
- Parameters
-
| list | the list of hex bytes to print |
| end | the character to end the print with |
◆ new_uuid()
Creates a new UUID.
The UUID comes from /proc/sys/kernel/random/uuid
- Returns
- a new UUID
◆ to_hex()
| ListHexByte to_hex |
( |
uint64_t | n | ) |
|
Converts an entire 64-bit integer into the character representation.
Caller must free memory.
- Parameters
-
- Returns
- the List of bytes the number represents
◆ to_hex1()
Converts a single byte to the character representation.
- Parameters
-
- Returns
- a HexByte that represents that byte
◆ UUID_deserialize()
◆ UUID_eq()
Compare 2 UUID's.
- Parameters
-
| lhs | the left-hand side of the equality |
| rhs | the right-hand side of the equality |
- Returns
- whether the 2 UUID's ar equal or not
◆ UUID_serialize()