Bitcoin ABC 0.30.5
P2P Digital Currency
node.h
Go to the documentation of this file.
1// Copyright (c) 2018-2019 The Bitcoin developers
2// Distributed under the MIT software license, see the accompanying
3// file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
5#ifndef BITCOIN_AVALANCHE_NODE_H
6#define BITCOIN_AVALANCHE_NODE_H
7
8#include <nodeid.h>
9#include <pubkey.h>
10#include <util/time.h>
11
12#include <chrono>
13#include <cstdint>
14
15using PeerId = uint32_t;
16static constexpr PeerId NO_PEER = -1;
17
18namespace avalanche {
19
20struct Node {
25
26 Node(NodeId nodeid_, PeerId peerid_)
27 : nodeid(nodeid_), peerid(peerid_),
29};
30
31} // namespace avalanche
32
33#endif // BITCOIN_AVALANCHE_NODE_H
static constexpr PeerId NO_PEER
Definition: node.h:16
uint32_t PeerId
Definition: node.h:15
int64_t NodeId
Definition: nodeid.h:10
PeerId peerid
Definition: node.h:22
SteadyMilliseconds nextRequestTime
Definition: node.h:23
NodeId nodeid
Definition: node.h:21
bool avaproofsSent
Definition: node.h:24
Node(NodeId nodeid_, PeerId peerid_)
Definition: node.h:26
constexpr T Now()
Return the current time point cast to the given precision.
Definition: time.h:109
std::chrono::time_point< std::chrono::steady_clock, std::chrono::milliseconds > SteadyMilliseconds
Definition: time.h:31