diff options
author | Marcello Stanisci <stanisci.m@gmail.com> | 2018-02-16 11:59:32 +0100 |
---|---|---|
committer | Marcello Stanisci <stanisci.m@gmail.com> | 2018-02-16 11:59:32 +0100 |
commit | 7ffc6d0fb94592270a6a85f2dc8db9ec833d3565 (patch) | |
tree | 41d2a35fbffcc357c877d3a5921abd512a65c955 /src/include/taler_testing_lib.h | |
parent | 513a22c34404d87c0fba1f6054ef049553e19d6e (diff) |
hash code trait
Diffstat (limited to 'src/include/taler_testing_lib.h')
-rw-r--r-- | src/include/taler_testing_lib.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/include/taler_testing_lib.h b/src/include/taler_testing_lib.h index f7af83311..34f3217ff 100644 --- a/src/include/taler_testing_lib.h +++ b/src/include/taler_testing_lib.h @@ -1332,4 +1332,30 @@ TALER_TESTING_make_trait_amount_obj ( const struct TALER_Amount *amount); +/** + * Obtain a hash code from @a cmd. + * + * @param cmd command to extract trait from + * @param index which hash code to pick if @a cmd has multiple on + * offer + * @param wtid[out] set to the wanted hash code. + * @return #GNUNET_OK on success + */ +int +TALER_TESTING_get_trait_hash + (const struct TALER_TESTING_Command *cmd, + unsigned int index, + struct GNUNET_HashCode **hash); + +/** + * @param index associate the hash code with this index + * @param hash which hash code should be returned + * + * @return the trait, to be put in the traits array of the command + */ +struct TALER_TESTING_Trait +TALER_TESTING_make_trait_hash + (unsigned int index, + struct GNUNET_HashCode *hash); + #endif |