From 9cce35d27027e1e72e44ac8965ae687d75f1c93d Mon Sep 17 00:00:00 2001 From: Joseph Date: Wed, 29 Mar 2023 11:18:20 -0400 Subject: New sql code for batch ensure coin known --- src/include/taler_exchangedb_plugin.h | 36 ++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) (limited to 'src/include') diff --git a/src/include/taler_exchangedb_plugin.h b/src/include/taler_exchangedb_plugin.h index 962bccaa2..cee8fb883 100644 --- a/src/include/taler_exchangedb_plugin.h +++ b/src/include/taler_exchangedb_plugin.h @@ -29,6 +29,19 @@ #include "taler_extensions_policy.h" + + +struct TALER_EXCHANGEDB_CoinInfo +{ + uint64_t *known_coin_id; + struct TALER_DenominationHashP *denom_hash; + struct TALER_AgeCommitmentHash *h_age_commitment; + bool *existed; +}; + + + + /** * Information about a denomination key. */ @@ -887,6 +900,21 @@ struct TALER_EXCHANGEDB_DenominationKeyMetaData }; + + + + + + + + + + + + + + + /** * Signature of a function called with information about the exchange's * denomination keys. @@ -4027,7 +4055,13 @@ struct TALER_EXCHANGEDB_Plugin struct TALER_DenominationHashP *denom_pub_hash, struct TALER_AgeCommitmentHash *age_hash); - + enum TALER_EXCHANGEDB_CoinKnownStatus + (*batch_ensure_coin_known)(void *cls, + const struct TALER_CoinPublicInfo *coin, + const struct + TALER_EXCHANGEDB_CoinInfo *result, + unsigned int coin_length, + unsigned int batch_size); /** * Retrieve information about the given @a coin from the database. * -- cgit v1.2.3