aboutsummaryrefslogtreecommitdiff
path: root/src/core/gnunet-service-core_typemap.h
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2011-10-11 08:56:00 +0000
committerChristian Grothoff <christian@grothoff.org>2011-10-11 08:56:00 +0000
commit8afe6f260b19f148398784a2a918006b91bb4096 (patch)
tree6cd8160e8e0a183d4071d75abcbbde90b4d532f1 /src/core/gnunet-service-core_typemap.h
parent1f0797c47af2a197b05ac640ce17adc86982d3c0 (diff)
downloadgnunet-8afe6f260b19f148398784a2a918006b91bb4096.tar.gz
gnunet-8afe6f260b19f148398784a2a918006b91bb4096.zip
process inbound type map messages:
Diffstat (limited to 'src/core/gnunet-service-core_typemap.h')
-rw-r--r--src/core/gnunet-service-core_typemap.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/src/core/gnunet-service-core_typemap.h b/src/core/gnunet-service-core_typemap.h
index 10c614a85..72eb5b566 100644
--- a/src/core/gnunet-service-core_typemap.h
+++ b/src/core/gnunet-service-core_typemap.h
@@ -61,6 +61,16 @@ GSC_TYPEMAP_compute_type_map_message (void);
61 61
62 62
63/** 63/**
64 * Extract a type map from a TYPE_MAP message.
65 *
66 * @param msg a type map message
67 * @return NULL on error
68 */
69struct GSC_TypeMap *
70GSC_TYPEMAP_get_from_message (const struct GNUNET_MessageHeader *msg);
71
72
73/**
64 * Test if any of the types from the types array is in the 74 * Test if any of the types from the types array is in the
65 * given type map. 75 * given type map.
66 * 76 *
@@ -76,6 +86,29 @@ GSC_TYPEMAP_test_match (const struct GSC_TypeMap *tmap,
76 86
77 87
78/** 88/**
89 * Add additional types to a given typemap.
90 *
91 * @param map map to extend (not changed)
92 * @param types array of types to add
93 * @param tcnt number of entries in types
94 * @return updated type map (fresh copy)
95 */
96struct GSC_TypeMap *
97GSC_TYPEMAP_extend (const struct GSC_TypeMap *tmap,
98 const uint16_t *types,
99 unsigned int tcnt);
100
101
102/**
103 * Free the given type map.
104 *
105 * @param map a type map
106 */
107void
108GSC_TYPEMAP_destroy (struct GSC_TypeMap *tmap);
109
110
111/**
79 * Initialize typemap subsystem. 112 * Initialize typemap subsystem.
80 */ 113 */
81void 114void