std::vector<COutput> vCoins;
wallet->AvailableCoins(vCoins, true, coinControl);
- BOOST_FOREACH(const COutput& out, vCoins)
+ for (const COutput& out : vCoins)
if(out.fSpendable)
nBalance += out.tx->vout[out.i].nValue;
// returns a list of COutputs from COutPoints
void WalletModel::getOutputs(const std::vector<COutPoint>& vOutpoints, std::vector<COutput>& vOutputs)
{
- BOOST_FOREACH(const COutPoint& outpoint, vOutpoints)
+ for (const COutPoint& outpoint : vOutpoints)
{
if (!wallet->mapWallet.count(outpoint.hash)) continue;
COutput out(&wallet->mapWallet[outpoint.hash], outpoint.n, wallet->mapWallet[outpoint.hash].GetDepthInMainChain(), true);
std::vector<COutPoint> vLockedCoins;
// add locked coins
- BOOST_FOREACH(const COutPoint& outpoint, vLockedCoins)
+ for (const COutPoint& outpoint : vLockedCoins)
{
if (!wallet->mapWallet.count(outpoint.hash)) continue;
COutput out(&wallet->mapWallet[outpoint.hash], outpoint.n, wallet->mapWallet[outpoint.hash].GetDepthInMainChain(), true);
vCoins.push_back(out);
}
- BOOST_FOREACH(const COutput& out, vCoins)
+ for (const COutput& out : vCoins)
{
COutput cout = out;