diff options
Diffstat (limited to 'src/include/gnunet_sensor_util_lib.h')
-rw-r--r-- | src/include/gnunet_sensor_util_lib.h | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/src/include/gnunet_sensor_util_lib.h b/src/include/gnunet_sensor_util_lib.h index 1e5108d29..a9651bc1b 100644 --- a/src/include/gnunet_sensor_util_lib.h +++ b/src/include/gnunet_sensor_util_lib.h | |||
@@ -258,10 +258,56 @@ struct GNUNET_SENSOR_SensorBriefMessage | |||
258 | 258 | ||
259 | }; | 259 | }; |
260 | 260 | ||
261 | /** | ||
262 | * Used to communicate full information about a sensor. | ||
263 | */ | ||
264 | struct GNUNET_SENSOR_SensorFullMessage | ||
265 | { | ||
266 | |||
267 | /** | ||
268 | * GNUNET general message header. | ||
269 | */ | ||
270 | struct GNUNET_MessageHeader header; | ||
271 | |||
272 | /** | ||
273 | * Size of the config file carrying full sensor information. | ||
274 | * Allocated at position 0 after this struct. | ||
275 | */ | ||
276 | uint16_t cfg_size; | ||
277 | |||
278 | /** | ||
279 | * Name of the file (usually script) associated with this sensor. | ||
280 | * At the moment we only support having one file since that's all our sensors | ||
281 | * need at the moment. | ||
282 | * The file name is allocated at position 1 after this struct. | ||
283 | */ | ||
284 | uint16_t scriptname_size; | ||
285 | |||
286 | /** | ||
287 | * Size of the file (usually script) associated with this sensor. | ||
288 | * The file binary is allocated at position 2 after this struct. | ||
289 | */ | ||
290 | uint16_t script_size; | ||
291 | |||
292 | }; | ||
293 | |||
261 | GNUNET_NETWORK_STRUCT_END | 294 | GNUNET_NETWORK_STRUCT_END |
262 | 295 | ||
263 | 296 | ||
264 | /** | 297 | /** |
298 | * Given two version numbers as major and minor, compare them. | ||
299 | * | ||
300 | * @param v1_major First part of first version number | ||
301 | * @param v1_minor Second part of first version number | ||
302 | * @param v2_major First part of second version number | ||
303 | * @param v2_minor Second part of second version number | ||
304 | */ | ||
305 | int | ||
306 | GNUNET_SENSOR_version_compare (uint16_t v1_major, uint16_t v1_minor, | ||
307 | uint16_t v2_major, uint16_t v2_minor); | ||
308 | |||
309 | |||
310 | /** | ||
265 | * Reads sensor definitions from local data files | 311 | * Reads sensor definitions from local data files |
266 | * | 312 | * |
267 | * @return a multihashmap of loaded sensors | 313 | * @return a multihashmap of loaded sensors |