Vuo 2.4.4
Loading...
Searching...
No Matches
VuoUuid.h
Go to the documentation of this file.
1
10#ifndef VuoUuid_h
11#define VuoUuid_h
12
13#ifdef __cplusplus
14extern "C" {
15#endif
16
30typedef struct
31{
32 // can't return unsigned char[16] from VuoUuid_makeFromJson, so store in a struct.
33 unsigned char bytes[16];
34} VuoUuid;
35
36VuoUuid VuoUuid_makeFromJson(struct json_object * js);
37struct json_object * VuoUuid_getJson(const VuoUuid value);
38char * VuoUuid_getSummary(const VuoUuid value);
39
41
43
46char * VuoUuid_getString(const VuoUuid value);
50
56static inline bool VuoUuid_areEqual(const VuoUuid value1, const VuoUuid value2) __attribute__((optnone)) // https://b33p.net/kosada/vuo/vuo/-/issues/9141
57{
58 return value1.bytes[ 0] == value2.bytes[ 0] &&
59 value1.bytes[ 1] == value2.bytes[ 1] &&
60 value1.bytes[ 2] == value2.bytes[ 2] &&
61 value1.bytes[ 3] == value2.bytes[ 3] &&
62 value1.bytes[ 4] == value2.bytes[ 4] &&
63 value1.bytes[ 5] == value2.bytes[ 5] &&
64 value1.bytes[ 6] == value2.bytes[ 6] &&
65 value1.bytes[ 7] == value2.bytes[ 7] &&
66 value1.bytes[ 8] == value2.bytes[ 8] &&
67 value1.bytes[ 9] == value2.bytes[ 9] &&
68 value1.bytes[10] == value2.bytes[10] &&
69 value1.bytes[11] == value2.bytes[11] &&
70 value1.bytes[12] == value2.bytes[12] &&
71 value1.bytes[13] == value2.bytes[13] &&
72 value1.bytes[14] == value2.bytes[14] &&
73 value1.bytes[15] == value2.bytes[15];
74}
75
80#ifdef __cplusplus
81}
82#endif
83
84#endif