GNUnet 0.22.2
GNUNET_TESTING_Trait Struct Reference

A struct GNUNET_TESTING_Trait can be used to exchange data between cmds. More...

#include <gnunet_testing_lib.h>

Data Fields

unsigned int index
 Index number associated with the trait. More...
 
const char * trait_name
 Trait type, for example "reserve-pub" or "coin-priv". More...
 
const void * ptr
 Pointer to the piece of data to offer. More...
 

Detailed Description

A struct GNUNET_TESTING_Trait can be used to exchange data between cmds.

Therefore the cmd which like to provide data to other cmds has to implement the trait function, where an array of traits is defined with the help of the #GNUNET_TESTING_make_trait_ macro. The data can be retrieved with the help of the #GNUNET_TESTING_get_trait_ macro. Traits name and type must be defined to make use of the macros.

Definition at line 813 of file gnunet_testing_lib.h.

Field Documentation

◆ index

unsigned int GNUNET_TESTING_Trait::index

Index number associated with the trait.

This gives the possibility to have multiple traits on offer under the same name.

Definition at line 820 of file gnunet_testing_lib.h.

Referenced by barrier_reached_traits(), barrier_traits(), batch_traits(), connect_peers_traits(), GNUNET_TESTING_get_trait(), netjail_exec_traits(), start_peer_traits(), start_service_traits(), stop_peer_traits(), system_create_traits(), and traits().

◆ trait_name

const char* GNUNET_TESTING_Trait::trait_name

Trait type, for example "reserve-pub" or "coin-priv".

Definition at line 825 of file gnunet_testing_lib.h.

Referenced by GNUNET_TESTING_get_trait().

◆ ptr

const void* GNUNET_TESTING_Trait::ptr

Pointer to the piece of data to offer.

Definition at line 830 of file gnunet_testing_lib.h.

Referenced by GNUNET_TESTING_get_trait().


The documentation for this struct was generated from the following file: