bool CGovernanceManager::SerializeVoteForHash(const uint256& nHash, CDataStream& ss) const { LOCK(cs); CGovernanceObject* pGovobj = NULL; return cmapVoteToObject.Get(nHash,pGovobj) && pGovobj->GetVoteFile().SerializeVoteToStream(nHash, ss); }
bool CGovernanceManager::HaveVoteForHash(const uint256& nHash) const { LOCK(cs); CGovernanceObject* pGovobj = NULL; return cmapVoteToObject.Get(nHash, pGovobj) && pGovobj->GetVoteFile().HasVote(nHash); }
bool CGovernanceManager::HaveVoteForHash(uint256 nHash) { LOCK(cs); CGovernanceObject* pGovobj = NULL; if(!mapVoteToObject.Get(nHash,pGovobj)) { return false; } if(!pGovobj->GetVoteFile().HasVote(nHash)) { return false; } return true; }
bool CGovernanceManager::SerializeVoteForHash(uint256 nHash, CDataStream& ss) { LOCK(cs); CGovernanceObject* pGovobj = NULL; if(!mapVoteToObject.Get(nHash,pGovobj)) { return false; } CGovernanceVote vote; if(!pGovobj->GetVoteFile().GetVote(nHash, vote)) { return false; } ss << vote; return true; }