BitShares-Core  5.1.0
BitShares blockchain implementation and command-line interface software
Classes | Public Member Functions | List of all members
graphene::net::simulated_network Class Reference

#include <node.hpp>

Inheritance diagram for graphene::net::simulated_network:


struct  node_info

Public Member Functions

 ~simulated_network ()
 simulated_network (const std::string &user_agent)
void listen_to_p2p_network () override
void connect_to_p2p_network () override
void connect_to_endpoint (const fc::ip::endpoint &ep) override
fc::ip::endpoint get_actual_listening_endpoint () const override
void sync_from (const item_id &current_head_block, const std::vector< uint32_t > &hard_fork_block_numbers) override
void broadcast (const message &item_to_broadcast) override
void add_node_delegate (node_delegate *node_delegate_to_add)
virtual uint32_t get_connection_count () const override
- Public Member Functions inherited from graphene::net::node
 node (const std::string &user_agent)
virtual ~node ()
void close ()
void set_node_delegate (node_delegate *del)
void load_configuration (const fc::path &configuration_directory)
void add_node (const fc::ip::endpoint &ep)
void add_seed_nodes (std::vector< std::string > seeds)
void add_seed_node (const std::string &in)
void listen_on_endpoint (const fc::ip::endpoint &ep, bool wait_if_not_available)
void accept_incoming_connections (bool accept)
void listen_on_port (uint16_t port, bool wait_if_not_available)
std::vector< peer_statusget_connected_peers () const
virtual void broadcast_transaction (const signed_transaction &trx)
bool is_connected () const
void set_advanced_node_parameters (const fc::variant_object &params)
fc::variant_object get_advanced_node_parameters ()
message_propagation_data get_transaction_propagation_data (const graphene::protocol::transaction_id_type &transaction_id)
message_propagation_data get_block_propagation_data (const graphene::protocol::block_id_type &block_id)
node_id_t get_node_id () const
void set_allowed_peers (const std::vector< node_id_t > &allowed_peers)
void clear_peer_database ()
void set_total_bandwidth_limit (uint32_t upload_bytes_per_second, uint32_t download_bytes_per_second)
fc::variant_object network_get_info () const
fc::variant_object network_get_usage_stats () const
std::vector< potential_peer_recordget_potential_peers () const
void disable_peer_advertising ()
fc::variant_object get_call_statistics () const

Additional Inherited Members

- Static Public Member Functions inherited from graphene::net::node
static std::vector< fc::ip::endpointresolve_string_to_ip_endpoints (const std::string &in)
 Helper to convert a string to a collection of endpoints. More...

Detailed Description

Definition at line 324 of file node.hpp.

Constructor & Destructor Documentation

graphene::net::simulated_network::~simulated_network ( )

Definition at line 5052 of file node.cpp.

graphene::net::simulated_network::simulated_network ( const std::string &  user_agent)

Definition at line 328 of file node.hpp.

Member Function Documentation

void graphene::net::simulated_network::add_node_delegate ( node_delegate node_delegate_to_add)

Definition at line 5096 of file node.cpp.

void graphene::net::simulated_network::broadcast ( const message item_to_broadcast)

Add message to outgoing inventory list, notify peers that I have a message ready.

Reimplemented from graphene::net::node.

Definition at line 5086 of file node.cpp.

void graphene::net::simulated_network::connect_to_endpoint ( const fc::ip::endpoint ep)

Attempt to connect to the specified endpoint immediately.

Reimplemented from graphene::net::node.

Definition at line 331 of file node.hpp.

void graphene::net::simulated_network::connect_to_p2p_network ( )

Reimplemented from graphene::net::node.

Definition at line 330 of file node.hpp.

fc::ip::endpoint graphene::net::simulated_network::get_actual_listening_endpoint ( ) const

Returns the endpoint the node is listening on. This is usually the same as the value previously passed in to listen_on_endpoint, unless we were unable to bind to that port.

Reimplemented from graphene::net::node.

Definition at line 333 of file node.hpp.

virtual uint32_t graphene::net::simulated_network::get_connection_count ( ) const

return the number of peers we're actively connected to

Reimplemented from graphene::net::node.

Definition at line 339 of file node.hpp.

void graphene::net::simulated_network::listen_to_p2p_network ( )

Reimplemented from graphene::net::node.

Definition at line 329 of file node.hpp.

void graphene::net::simulated_network::sync_from ( const item_id current_head_block,
const std::vector< uint32_t > &  hard_fork_block_numbers 

Node starts the process of fetching all items after item_id of the given item_type. During this process messages are not broadcast.

Reimplemented from graphene::net::node.

Definition at line 335 of file node.hpp.

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