MCPcopy Create free account
hub / github.com/ElementsProject/elements / GetAddrBytes

Method GetAddrBytes

src/netaddress.cpp:826–834  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

824}
825
826std::vector<unsigned char> CNetAddr::GetAddrBytes() const
827{
828 if (IsAddrV1Compatible()) {
829 uint8_t serialized[V1_SERIALIZATION_SIZE];
830 SerializeV1Array(serialized);
831 return {std::begin(serialized), std::end(serialized)};
832 }
833 return std::vector<unsigned char>(m_addr.begin(), m_addr.end());
834}
835
836// private extensions to enum Network, only returned by GetExtNetwork,
837// and only used in GetReachabilityFrom

Callers 4

IsDiscouragedMethod · 0.80
DiscourageMethod · 0.80
GetAddressesMethod · 0.80
operator==Method · 0.80

Calls 4

beginFunction · 0.85
endFunction · 0.85
beginMethod · 0.45
endMethod · 0.45

Tested by 1

operator==Method · 0.64