bitcoin/chainparams: add an utility to retrieve chainparams for all networks

This commit is contained in:
darosior
2019-11-28 15:10:08 +01:00
committed by Christian Decker
parent e6b8a02446
commit 4b13b88f6c
2 changed files with 15 additions and 0 deletions

View File

@@ -46,6 +46,12 @@ struct chainparams {
*/
const struct chainparams *chainparams_for_network(const char *network_name);
/**
* chainparams_for_networks - Get blockchain parameters for all known networks,
* as a tal array.
*/
const struct chainparams **chainparams_for_networks(const tal_t *ctx);
/**
* chainparams_by_bip173 - Helper to get a network by its bip173 name
*