Changeset View
Changeset View
Standalone View
Standalone View
src/interfaces/wallet.h
// Copyright (c) 2018 The Bitcoin Core developers | // Copyright (c) 2018 The Bitcoin Core developers | ||||
// Distributed under the MIT software license, see the accompanying | // Distributed under the MIT software license, see the accompanying | ||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | // file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
#ifndef BITCOIN_INTERFACES_WALLET_H | #ifndef BITCOIN_INTERFACES_WALLET_H | ||||
#define BITCOIN_INTERFACES_WALLET_H | #define BITCOIN_INTERFACES_WALLET_H | ||||
#include <amount.h> // For Amount | #include <amount.h> // For Amount | ||||
#include <primitives/blockhash.h> | |||||
#include <primitives/transaction.h> // For CTxOut | #include <primitives/transaction.h> // For CTxOut | ||||
#include <pubkey.h> // For CKeyID and CScriptID (definitions needed in CTxDestination instantiation) | #include <pubkey.h> // For CKeyID and CScriptID (definitions needed in CTxDestination instantiation) | ||||
#include <script/sighashtype.h> | #include <script/sighashtype.h> | ||||
#include <script/standard.h> // For CTxDestination | #include <script/standard.h> // For CTxDestination | ||||
#include <support/allocators/secure.h> // For SecureString | #include <support/allocators/secure.h> // For SecureString | ||||
#include <util/message.h> | #include <util/message.h> | ||||
#include <util/ui_change_type.h> | #include <util/ui_change_type.h> | ||||
▲ Show 20 Lines • Show All 177 Lines • ▼ Show 20 Lines | virtual TransactionError fillPSBT(SigHashType sighash_type, bool sign, | ||||
bool bip32derivs, | bool bip32derivs, | ||||
PartiallySignedTransaction &psbtx, | PartiallySignedTransaction &psbtx, | ||||
bool &complete) const = 0; | bool &complete) const = 0; | ||||
//! Get balances. | //! Get balances. | ||||
virtual WalletBalances getBalances() = 0; | virtual WalletBalances getBalances() = 0; | ||||
//! Get balances if possible without blocking. | //! Get balances if possible without blocking. | ||||
virtual bool tryGetBalances(WalletBalances &balances, int &num_blocks) = 0; | virtual bool tryGetBalances(WalletBalances &balances, | ||||
BlockHash &block_hash) = 0; | |||||
//! Get balance. | //! Get balance. | ||||
virtual Amount getBalance() = 0; | virtual Amount getBalance() = 0; | ||||
//! Get available balance. | //! Get available balance. | ||||
virtual Amount getAvailableBalance(const CCoinControl &coin_control) = 0; | virtual Amount getAvailableBalance(const CCoinControl &coin_control) = 0; | ||||
//! Return whether transaction input belongs to wallet. | //! Return whether transaction input belongs to wallet. | ||||
▲ Show 20 Lines • Show All 171 Lines • Show Last 20 Lines |