mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Functions for owned nodes (nodes that have a single other node that owns
them) and dual-owner nodes (nodes that have two other nodes that own them). Owned nodes would be things like nicknames. Dual-owner nodes would be things like ripple balances.
This commit is contained in:
@@ -109,6 +109,31 @@ bool SerializedLedgerEntry::thread(const uint256& txID, uint32 ledgerSeq, uint25
|
||||
return true;
|
||||
}
|
||||
|
||||
bool SerializedLedgerEntry::hasOneOwner()
|
||||
{
|
||||
return (mType != ltACCOUNT_ROOT) && (getIFieldIndex(sfAccount) != -1);
|
||||
}
|
||||
|
||||
bool SerializedLedgerEntry::hasTwoOwners()
|
||||
{
|
||||
return mType == ltRIPPLE_STATE;
|
||||
}
|
||||
|
||||
NewcoinAddress SerializedLedgerEntry::getOwner()
|
||||
{
|
||||
return getIValueFieldAccount(sfAccount);
|
||||
}
|
||||
|
||||
NewcoinAddress SerializedLedgerEntry::getFirstOwner()
|
||||
{
|
||||
return getIValueFieldAccount(sfLowID);
|
||||
}
|
||||
|
||||
NewcoinAddress SerializedLedgerEntry::getSecondOwner()
|
||||
{
|
||||
return getIValueFieldAccount(sfHighID);
|
||||
}
|
||||
|
||||
std::vector<uint256> SerializedLedgerEntry::getOwners()
|
||||
{
|
||||
std::vector<uint256> owners;
|
||||
|
||||
Reference in New Issue
Block a user