Bitcoin Core  0.21.1
P2P Digital Currency
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules
Public Member Functions | Private Member Functions | Private Attributes | List of all members
V1TransportDeserializer Class Referencefinal

#include <net.h>

Inheritance diagram for V1TransportDeserializer:
[legend]
Collaboration diagram for V1TransportDeserializer:
[legend]

Public Member Functions

 V1TransportDeserializer (const CChainParams &chain_params, const NodeId node_id, int nTypeIn, int nVersionIn)
 
bool Complete () const override
 
void SetVersion (int nVersionIn) override
 
int Read (const char *pch, unsigned int nBytes) override
 
Optional< CNetMessageGetMessage (std::chrono::microseconds time, uint32_t &out_err_raw_size) override
 
- Public Member Functions inherited from TransportDeserializer
virtual ~TransportDeserializer ()
 

Private Member Functions

const uint256GetMessageHash () const
 
int readHeader (const char *pch, unsigned int nBytes)
 
int readData (const char *pch, unsigned int nBytes)
 
void Reset ()
 

Private Attributes

const CChainParamsm_chain_params
 
const NodeId m_node_id
 
CHash256 hasher
 
uint256 data_hash
 
bool in_data
 
CDataStream hdrbuf
 
CMessageHeader hdr
 
CDataStream vRecv
 
unsigned int nHdrPos
 
unsigned int nDataPos
 

Detailed Description

Definition at line 767 of file net.h.

Constructor & Destructor Documentation

V1TransportDeserializer::V1TransportDeserializer ( const CChainParams chain_params,
const NodeId  node_id,
int  nTypeIn,
int  nVersionIn 
)
inline

Definition at line 797 of file net.h.

Member Function Documentation

bool V1TransportDeserializer::Complete ( ) const
inlineoverridevirtual

Implements TransportDeserializer.

Definition at line 806 of file net.h.

Optional<CNetMessage> V1TransportDeserializer::GetMessage ( std::chrono::microseconds  time,
uint32_t &  out_err_raw_size 
)
overridevirtual

Implements TransportDeserializer.

const uint256& V1TransportDeserializer::GetMessageHash ( ) const
private
int V1TransportDeserializer::Read ( const char *  pch,
unsigned int  nBytes 
)
inlineoverridevirtual

Implements TransportDeserializer.

Definition at line 817 of file net.h.

int V1TransportDeserializer::readData ( const char *  pch,
unsigned int  nBytes 
)
private
int V1TransportDeserializer::readHeader ( const char *  pch,
unsigned int  nBytes 
)
private
void V1TransportDeserializer::Reset ( )
inlineprivate

Definition at line 785 of file net.h.

Here is the call graph for this function:

void V1TransportDeserializer::SetVersion ( int  nVersionIn)
inlineoverridevirtual

Implements TransportDeserializer.

Definition at line 812 of file net.h.

Here is the call graph for this function:

Member Data Documentation

uint256 V1TransportDeserializer::data_hash
mutableprivate

Definition at line 773 of file net.h.

CHash256 V1TransportDeserializer::hasher
mutableprivate

Definition at line 772 of file net.h.

CMessageHeader V1TransportDeserializer::hdr
private

Definition at line 776 of file net.h.

CDataStream V1TransportDeserializer::hdrbuf
private

Definition at line 775 of file net.h.

bool V1TransportDeserializer::in_data
private

Definition at line 774 of file net.h.

const CChainParams& V1TransportDeserializer::m_chain_params
private

Definition at line 770 of file net.h.

const NodeId V1TransportDeserializer::m_node_id
private

Definition at line 771 of file net.h.

unsigned int V1TransportDeserializer::nDataPos
private

Definition at line 779 of file net.h.

unsigned int V1TransportDeserializer::nHdrPos
private

Definition at line 778 of file net.h.

CDataStream V1TransportDeserializer::vRecv
private

Definition at line 777 of file net.h.


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