CatapultServer
v0.5.0.1 (Elephant)
|
Go to the documentation of this file.
26 class NodeContainerView;
31 namespace catapult {
namespace nodediscovery {
#define CATAPULT_LOG(SEV)
Writes a log entry to the default logger with SEV severity.
Definition: Logging.h:340
bool TryParseNodesPacket(const ionet::Packet &packet, ionet::NodeSet &nodes)
Tries to parse packet into nodes.
Definition: NodePingUtils.cpp:39
Node UnpackNode(const NetworkNode &networkNode)
Unpacks a network node (networkNode) into a node model.
Definition: NetworkNode.cpp:59
A packet header with a data payload.
Definition: Packet.h:32
const Key & identityKey() const
Gets the unique identifier (a public key).
Definition: Node.cpp:60
def warning(*args)
Definition: colorPrint.py:10
bool IsNodeCompatible(const ionet::Node &node, model::NetworkIdentifier networkIdentifier, const Key &identityKey)
Determines if node is compatible with expected network (networkIdentifier) and identity (identityKey)...
Definition: NodePingUtils.cpp:52
uint8_t * Data()
Returns a non-const pointer to data contained in this packet.
Definition: Packet.h:35
bool contains(const Key &identityKey) const
Returns true if the node with identityKey is in the container, false otherwise.
Definition: NodeContainer.cpp:80
A read only view on top of node container.
Definition: NodeContainer.h:39
size_t CalculatePacketDataSize(const Packet &packet)
Calculates the data size of packet.
Definition: PacketEntityUtils.h:29
bool TryParseNodePacket(const ionet::Packet &packet, ionet::Node &node)
Tries to parse packet into node.
Definition: NodePingUtils.cpp:28
std::unordered_set< Node, NodeHasher > NodeSet
A set of nodes.
Definition: Node.h:128
NetworkIdentifier
Possible network identifiers.
Definition: NetworkInfo.h:45
const NodeMetadata & metadata() const
Gets tne metadata.
Definition: Node.cpp:68
ionet::Node Node
Definition: PacketWriters.cpp:45
Definition: AddressExtractionExtension.cpp:28
Base class for wrappers of byte array types, to provide some type-safety.
Definition: ByteArray.h:29
A node in the catapult network.
Definition: Node.h:82
utils::ByteArray< Key_Size, Key_tag > Key
Definition: src/catapult/types.h:41
ionet::NodeSet SelectUnknownNodes(const ionet::NodeContainerView &view, const ionet::NodeSet &nodes)
Filters nodes by returning all nodes not contained in view.
Definition: NodePingUtils.cpp:56