Skip to content

Commit 9a5c090

Browse files
committed
wallet: Introducing StakeableOutput class.
1 parent f9edbd5 commit 9a5c090

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

src/wallet/wallet.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4430,3 +4430,8 @@ bool CWalletTx::IsFromMe(const isminefilter& filter) const
44304430
{
44314431
return (GetDebit(filter) > 0);
44324432
}
4433+
4434+
CStakeableOutput::CStakeableOutput(const CWalletTx* txIn, int iIn, int nDepthIn, bool fSpendableIn, bool fSolvableIn,
4435+
const CBlockIndex*& _pindex) : COutput(txIn, iIn, nDepthIn, fSpendableIn, fSolvableIn),
4436+
pindex(_pindex) {}
4437+

src/wallet/wallet.h

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ class CAddressBookIterator;
9696
class CAccountingEntry;
9797
class CCoinControl;
9898
class COutput;
99+
class CStakeableOutput;
99100
class CReserveKey;
100101
class CScript;
101102
class CWalletTx;
@@ -1072,6 +1073,15 @@ class COutput
10721073
std::string ToString() const;
10731074
};
10741075

1076+
class CStakeableOutput : public COutput
1077+
{
1078+
public:
1079+
const CBlockIndex* pindex{nullptr};
1080+
1081+
CStakeableOutput(const CWalletTx* txIn, int iIn, int nDepthIn, bool fSpendableIn, bool fSolvableIn,
1082+
const CBlockIndex*& pindex);
1083+
1084+
};
10751085

10761086
/** Private key that includes an expiration date in case it never gets used. */
10771087
class CWalletKey

0 commit comments

Comments
 (0)