summaryrefslogtreecommitdiffstats
path: root/uca-net-protocol.h
diff options
context:
space:
mode:
authorMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2017-10-10 17:03:52 +0200
committerMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2017-10-10 17:03:52 +0200
commit74f1bde37dd4363e3fe3251b2a3567b3666d3a14 (patch)
treeab945a0717aa70ef92a8d353864d678646c34d93 /uca-net-protocol.h
parent8317ec2fe9c892091c1c3d021277775e91435e95 (diff)
downloaduca-net-74f1bde37dd4363e3fe3251b2a3567b3666d3a14.tar.gz
uca-net-74f1bde37dd4363e3fe3251b2a3567b3666d3a14.tar.bz2
uca-net-74f1bde37dd4363e3fe3251b2a3567b3666d3a14.tar.xz
uca-net-74f1bde37dd4363e3fe3251b2a3567b3666d3a14.zip
Improve custom enum handling
Diffstat (limited to 'uca-net-protocol.h')
-rw-r--r--uca-net-protocol.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/uca-net-protocol.h b/uca-net-protocol.h
index 4a1b5b6..1460cbd 100644
--- a/uca-net-protocol.h
+++ b/uca-net-protocol.h
@@ -3,6 +3,8 @@
#include <gio/gio.h>
+#define UCA_NET_MAX_ENUM_LENGTH 128
+
typedef enum {
UCA_NET_MESSAGE_INVALID = 0,
UCA_NET_MESSAGE_GET_PROPERTIES,
@@ -86,6 +88,13 @@ typedef struct {
struct {
gchar default_value[128];
} gstring;
+ struct {
+ gint default_value;
+ gint minimum;
+ gint maximum;
+ guint n_values;
+ gint values[UCA_NET_MAX_ENUM_LENGTH];
+ } genum;
NUMERIC_STRUCT (gint)
NUMERIC_STRUCT (guint)
NUMERIC_STRUCT (gfloat)