26#ifndef GNUNET_SERVICE_CORE_TYPEMAP_H
27#define GNUNET_SERVICE_CORE_TYPEMAP_H
112 const uint16_t *types,
126 const uint16_t *types,
struct GNUNET_MessageHeader * msg
struct GNUNET_MessageHeader * GSC_TYPEMAP_compute_type_map_message(void)
Compute a type map message for this peer.
struct GSC_TypeMap * GSC_TYPEMAP_extend(const struct GSC_TypeMap *tmap, const uint16_t *types, unsigned int tcnt)
Add additional types to a given typemap.
void GSC_TYPEMAP_init(void)
Initialize typemap subsystem.
void GSC_TYPEMAP_destroy(struct GSC_TypeMap *tmap)
Free the given type map.
int GSC_TYPEMAP_check_hash(const struct GNUNET_HashCode *hc)
Check if the given hash matches our current type map.
struct GSC_TypeMap * GSC_TYPEMAP_get_from_message(const struct GNUNET_MessageHeader *msg)
Extract a type map from a #GNUNET_MESSAGE_TYPE_CORE_COMRESSED_TYPE_MAP or GNUNET_MESSAGE_TYPE_CORE_BI...
int GSC_TYPEMAP_test_match(const struct GSC_TypeMap *tmap, const uint16_t *types, unsigned int tcnt)
Test if any of the types from the types array is in the given type map.
void GSC_TYPEMAP_done(void)
Shutdown typemap subsystem.
void GSC_TYPEMAP_add(const uint16_t *types, unsigned int tlen)
Add a set of types to our type map.
struct GSC_TypeMap * GSC_TYPEMAP_create(void)
Create an empty type map.
void GSC_TYPEMAP_hash(const struct GSC_TypeMap *tm, struct GNUNET_HashCode *hc)
Hash the contents of a type map.
void GSC_TYPEMAP_remove(const uint16_t *types, unsigned int tlen)
Remove a set of message types from our type map.
A type map describing which messages a given neighbour is able to process.