2 #ifndef ZIO_NODE_HPP_SEEN 3 #define ZIO_NODE_HPP_SEEN 34 std::string m_hostname;
36 std::unordered_map<std::string, portptr_t> m_ports;
37 std::vector<std::string> m_portnames;
38 bool m_verbose{
false};
43 const std::string& hostname=
"");
64 bool verbose()
const {
return m_verbose; }
An identified vertex in a ported, directed graph.
void online(const headerset_t &extra_headers={})
Bring the node online.
const std::vector< std::string > & portnames() const
Return names of all ports in order of their creation.
void set_nick(const nickname_t &nick)
Set the node nickname.
void set_verbose(bool verbose=true)
Set verbose for underlying Zyre and internal debug messages.
portptr_t port(const std::string &name, int stype)
Create a named port with the given socket type.
Node(nickname_t nick="", origin_t origin=0, const std::string &hostname="")
Create a node.
std::map< header_key_t, header_value_t > headerset_t
nickname_t nick() const
Return a previously set node nickname.
origin_t origin() const
Return a previously set node origin.
void set_origin(origin_t origin)
Set the node origin.
std::shared_ptr< Port > portptr_t
The context can't be copied and ports like to be shared.
std::string nickname_t
A peer asserts a nickname.
void offline()
Bring the node offline.
implementation of ZIO data flow protocol endpoints
Peer at the network to discover peers and advertise self.