GNUnet  0.10.x
023.c
Go to the documentation of this file.
1 void *
3 {
4  static enum GNUNET_BLOCK_Type types[] =
5  {
6  GNUNET_BLOCK_TYPE_SERVICE_BLOCKYPE,
8  };
10 
12  api->evaluate = &block_plugin_SERICE_evaluate;
14  api->types = types;
15  return api;
16 }
17 
enum GNUNET_BLOCK_Type * types
0-terminated array of block types supported by this plugin.
Any type of block, used as a wildcard when searching.
GNUNET_BLOCK_EvaluationFunction evaluate
Main function of a block plugin.
GNUNET_BLOCK_Type
Blocks in the datastore and the datacache must have a unique type.
Each plugin is required to return a pointer to a struct of this type as the return value from its ent...
void * libgnunet_plugin_block_SERVICE_init(void *cls)
Definition: 023.c:2
#define GNUNET_new(type)
Allocate a struct or union of the given type.
static int block_plugin_SERVICE_get_key(void *cls, enum GNUNET_BLOCK_Type type, const void *block, size_t block_size, struct GNUNET_HashCode *key)
Definition: 022.c:2
GNUNET_BLOCK_GetKeyFunction get_key
Obtain the key for a given block (if possible).