coin.h raw

   1  // Copyright (c) 2019-present The Bitcoin Core developers
   2  // Distributed under the MIT software license, see the accompanying
   3  // file COPYING or http://www.opensource.org/licenses/mit-license.php.
   4  
   5  #ifndef BITCOIN_NODE_COIN_H
   6  #define BITCOIN_NODE_COIN_H
   7  
   8  #include <map>
   9  
  10  class COutPoint;
  11  class Coin;
  12  
  13  namespace node {
  14  struct NodeContext;
  15  
  16  /**
  17   * Look up unspent output information. Returns coins in the mempool and in the
  18   * current chain UTXO set. Iterates through all the keys in the map and
  19   * populates the values.
  20   *
  21   * @param[in] node The node context to use for lookup
  22   * @param[in,out] coins map to fill
  23   */
  24  void FindCoins(const node::NodeContext& node, std::map<COutPoint, Coin>& coins);
  25  } // namespace node
  26  
  27  #endif // BITCOIN_NODE_COIN_H
  28