1 |
/* Generated by the protocol buffer compiler. DO NOT EDIT! */ |
---|
2 |
|
---|
3 |
#ifndef PROTOBUF_C_bundle_2eproto__INCLUDED |
---|
4 |
#define PROTOBUF_C_bundle_2eproto__INCLUDED |
---|
5 |
|
---|
6 |
#include <google/protobuf-c/protobuf-c.h> |
---|
7 |
|
---|
8 |
PROTOBUF_C_BEGIN_DECLS |
---|
9 |
|
---|
10 |
|
---|
11 |
typedef struct _Metric Metric; |
---|
12 |
typedef struct _Status Status; |
---|
13 |
typedef struct _Metadata Metadata; |
---|
14 |
typedef struct _Bundle Bundle; |
---|
15 |
|
---|
16 |
|
---|
17 |
/* --- enums --- */ |
---|
18 |
|
---|
19 |
|
---|
20 |
/* --- messages --- */ |
---|
21 |
|
---|
22 |
struct _Metric |
---|
23 |
{ |
---|
24 |
ProtobufCMessage base; |
---|
25 |
char *name; |
---|
26 |
int32_t metrictype; |
---|
27 |
protobuf_c_boolean has_valuedbl; |
---|
28 |
double valuedbl; |
---|
29 |
protobuf_c_boolean has_valuei64; |
---|
30 |
int64_t valuei64; |
---|
31 |
protobuf_c_boolean has_valueui64; |
---|
32 |
uint64_t valueui64; |
---|
33 |
protobuf_c_boolean has_valuei32; |
---|
34 |
int32_t valuei32; |
---|
35 |
protobuf_c_boolean has_valueui32; |
---|
36 |
uint32_t valueui32; |
---|
37 |
char *valuestr; |
---|
38 |
}; |
---|
39 |
#define METRIC__INIT \ |
---|
40 |
{ PROTOBUF_C_MESSAGE_INIT (&metric__descriptor) \ |
---|
41 |
, NULL, 0, 0,0, 0,0, 0,0, 0,0, 0,0, NULL } |
---|
42 |
|
---|
43 |
|
---|
44 |
struct _Status |
---|
45 |
{ |
---|
46 |
ProtobufCMessage base; |
---|
47 |
int32_t available; |
---|
48 |
int32_t state; |
---|
49 |
int32_t duration; |
---|
50 |
char *status; |
---|
51 |
}; |
---|
52 |
#define STATUS__INIT \ |
---|
53 |
{ PROTOBUF_C_MESSAGE_INIT (&status__descriptor) \ |
---|
54 |
, 0, 0, 0, NULL } |
---|
55 |
|
---|
56 |
|
---|
57 |
struct _Metadata |
---|
58 |
{ |
---|
59 |
ProtobufCMessage base; |
---|
60 |
char *key; |
---|
61 |
char *value; |
---|
62 |
}; |
---|
63 |
#define METADATA__INIT \ |
---|
64 |
{ PROTOBUF_C_MESSAGE_INIT (&metadata__descriptor) \ |
---|
65 |
, NULL, NULL } |
---|
66 |
|
---|
67 |
|
---|
68 |
struct _Bundle |
---|
69 |
{ |
---|
70 |
ProtobufCMessage base; |
---|
71 |
Status *status; |
---|
72 |
size_t n_metrics; |
---|
73 |
Metric **metrics; |
---|
74 |
size_t n_metadata; |
---|
75 |
Metadata **metadata; |
---|
76 |
}; |
---|
77 |
#define BUNDLE__INIT \ |
---|
78 |
{ PROTOBUF_C_MESSAGE_INIT (&bundle__descriptor) \ |
---|
79 |
, NULL, 0,NULL, 0,NULL } |
---|
80 |
|
---|
81 |
|
---|
82 |
/* Metric methods */ |
---|
83 |
void metric__init |
---|
84 |
(Metric *message); |
---|
85 |
size_t metric__get_packed_size |
---|
86 |
(const Metric *message); |
---|
87 |
size_t metric__pack |
---|
88 |
(const Metric *message, |
---|
89 |
uint8_t *out); |
---|
90 |
size_t metric__pack_to_buffer |
---|
91 |
(const Metric *message, |
---|
92 |
ProtobufCBuffer *buffer); |
---|
93 |
Metric * |
---|
94 |
metric__unpack |
---|
95 |
(ProtobufCAllocator *allocator, |
---|
96 |
size_t len, |
---|
97 |
const uint8_t *data); |
---|
98 |
void metric__free_unpacked |
---|
99 |
(Metric *message, |
---|
100 |
ProtobufCAllocator *allocator); |
---|
101 |
/* Status methods */ |
---|
102 |
void status__init |
---|
103 |
(Status *message); |
---|
104 |
size_t status__get_packed_size |
---|
105 |
(const Status *message); |
---|
106 |
size_t status__pack |
---|
107 |
(const Status *message, |
---|
108 |
uint8_t *out); |
---|
109 |
size_t status__pack_to_buffer |
---|
110 |
(const Status *message, |
---|
111 |
ProtobufCBuffer *buffer); |
---|
112 |
Status * |
---|
113 |
status__unpack |
---|
114 |
(ProtobufCAllocator *allocator, |
---|
115 |
size_t len, |
---|
116 |
const uint8_t *data); |
---|
117 |
void status__free_unpacked |
---|
118 |
(Status *message, |
---|
119 |
ProtobufCAllocator *allocator); |
---|
120 |
/* Metadata methods */ |
---|
121 |
void metadata__init |
---|
122 |
(Metadata *message); |
---|
123 |
size_t metadata__get_packed_size |
---|
124 |
(const Metadata *message); |
---|
125 |
size_t metadata__pack |
---|
126 |
(const Metadata *message, |
---|
127 |
uint8_t *out); |
---|
128 |
size_t metadata__pack_to_buffer |
---|
129 |
(const Metadata *message, |
---|
130 |
ProtobufCBuffer *buffer); |
---|
131 |
Metadata * |
---|
132 |
metadata__unpack |
---|
133 |
(ProtobufCAllocator *allocator, |
---|
134 |
size_t len, |
---|
135 |
const uint8_t *data); |
---|
136 |
void metadata__free_unpacked |
---|
137 |
(Metadata *message, |
---|
138 |
ProtobufCAllocator *allocator); |
---|
139 |
/* Bundle methods */ |
---|
140 |
void bundle__init |
---|
141 |
(Bundle *message); |
---|
142 |
size_t bundle__get_packed_size |
---|
143 |
(const Bundle *message); |
---|
144 |
size_t bundle__pack |
---|
145 |
(const Bundle *message, |
---|
146 |
uint8_t *out); |
---|
147 |
size_t bundle__pack_to_buffer |
---|
148 |
(const Bundle *message, |
---|
149 |
ProtobufCBuffer *buffer); |
---|
150 |
Bundle * |
---|
151 |
bundle__unpack |
---|
152 |
(ProtobufCAllocator *allocator, |
---|
153 |
size_t len, |
---|
154 |
const uint8_t *data); |
---|
155 |
void bundle__free_unpacked |
---|
156 |
(Bundle *message, |
---|
157 |
ProtobufCAllocator *allocator); |
---|
158 |
/* --- per-message closures --- */ |
---|
159 |
|
---|
160 |
typedef void (*Metric_Closure) |
---|
161 |
(const Metric *message, |
---|
162 |
void *closure_data); |
---|
163 |
typedef void (*Status_Closure) |
---|
164 |
(const Status *message, |
---|
165 |
void *closure_data); |
---|
166 |
typedef void (*Metadata_Closure) |
---|
167 |
(const Metadata *message, |
---|
168 |
void *closure_data); |
---|
169 |
typedef void (*Bundle_Closure) |
---|
170 |
(const Bundle *message, |
---|
171 |
void *closure_data); |
---|
172 |
|
---|
173 |
/* --- services --- */ |
---|
174 |
|
---|
175 |
|
---|
176 |
/* --- descriptors --- */ |
---|
177 |
|
---|
178 |
extern const ProtobufCMessageDescriptor metric__descriptor; |
---|
179 |
extern const ProtobufCMessageDescriptor status__descriptor; |
---|
180 |
extern const ProtobufCMessageDescriptor metadata__descriptor; |
---|
181 |
extern const ProtobufCMessageDescriptor bundle__descriptor; |
---|
182 |
|
---|
183 |
PROTOBUF_C_END_DECLS |
---|
184 |
|
---|
185 |
|
---|
186 |
#endif /* PROTOBUF_bundle_2eproto__INCLUDED */ |
---|