Bitcoin Core  22.99.0
P2P Digital Currency
Public Member Functions | List of all members
CAddrManSerializationMock Class Referenceabstract
Inheritance diagram for CAddrManSerializationMock:
Collaboration diagram for CAddrManSerializationMock:

Public Member Functions

virtual void Serialize (CDataStream &s) const =0
 CAddrManSerializationMock ()
- Public Member Functions inherited from CAddrMan
template<typename Stream >
void Serialize (Stream &s_) const EXCLUSIVE_LOCKS_REQUIRED(!cs)
template<typename Stream >
void Unserialize (Stream &s_) EXCLUSIVE_LOCKS_REQUIRED(!cs)
 CAddrMan (std::vector< bool > asmap, bool deterministic, int32_t consistency_check_ratio)
 ~CAddrMan ()
size_t size () const EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Return the number of (unique) addresses in all tables. More...
bool Add (const std::vector< CAddress > &vAddr, const CNetAddr &source, int64_t nTimePenalty=0) EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Add addresses to addrman's new table. More...
void Good (const CService &addr, int64_t nTime=GetAdjustedTime()) EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Mark an entry as accessible. More...
void Attempt (const CService &addr, bool fCountFailure, int64_t nTime=GetAdjustedTime()) EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Mark an entry as connection attempted to. More...
void ResolveCollisions () EXCLUSIVE_LOCKS_REQUIRED(!cs)
 See if any to-be-evicted tried table entries have been tested and if so resolve the collisions. More...
CAddrInfo SelectTriedCollision () EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Randomly select an address in tried that another address is attempting to evict. More...
CAddrInfo Select (bool newOnly=false) const EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Choose an address to connect to. More...
std::vector< CAddressGetAddr (size_t max_addresses, size_t max_pct, std::optional< Network > network) const EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Return all or many randomly selected addresses, optionally by network. More...
void Connected (const CService &addr, int64_t nTime=GetAdjustedTime()) EXCLUSIVE_LOCKS_REQUIRED(!cs)
 Outer function for Connected_() More...
void SetServices (const CService &addr, ServiceFlags nServices) EXCLUSIVE_LOCKS_REQUIRED(!cs)
const std::vector< bool > & GetAsmap () const

Detailed Description

Definition at line 24 of file addrman_tests.cpp.

Constructor & Destructor Documentation

◆ CAddrManSerializationMock()

CAddrManSerializationMock::CAddrManSerializationMock ( )

Definition at line 29 of file addrman_tests.cpp.

Member Function Documentation

◆ Serialize()

virtual void CAddrManSerializationMock::Serialize ( CDataStream s) const
pure virtual

Implemented in CAddrManCorrupted, and CAddrManUncorrupted.

The documentation for this class was generated from the following file: