#include <NodeID.h>
Public Member Functions | |
| NodeID (const std::string &ID) | |
| Constructor. | |
| NodeID (const std::string &hostname, int listenPort) | |
| Constructor for hostname and listen ports. | |
| NodeID (const NodeID &rhs) | |
| copy constructor | |
| const NodeID & | operator= (const NodeID &rhs) |
| Assignment operator. | |
| operator std::string () const | |
| Implicit conversion operator to std::string. | |
| operator const char * () const | |
| Implicit conversion operator to std::string. | |
| const std::string & | getHostname () const |
| Get the hostname portion of this object. | |
| int | getListenPort () const |
| Get the listen port portion of this object. | |
| bool | operator== (const NodeID &rhs) const |
| equality operator | |
| bool | operator!= (const NodeID &rhs) const |
| inequality operator | |
| bool | operator< (const NodeID &rhs) const |
| less than operator | |
Private Attributes | |
| std::string | ID_ |
| The ID in the form of hostname_port. | |
| std::string | hostname_ |
| The hostname. | |
| int | listenPort_ |
| The listen port. | |
Friends | |
| std::ostream & | operator<< (std::ostream &output, const NodeID &_node) |
| ostream operator | |
handles Fountain node identifcation in the form of hostname_listenport where hostname is the hostname truncated to the first period and listenport is the listening socket number that the Fountain node is using to accept new connections.
|
|
Constructor.
|
|
||||||||||||
|
Constructor for hostname and listen ports.
|
|
|
Get the hostname portion of this object.
|
|
|
Get the listen port portion of this object.
|
|
|
inequality operator
|
|
|
less than operator
|
|
|
equality operator
|
1.4.6