|
OverSim
|
A wrapper around either an I3IPAddress or an I3Identifier. More...
#include <I3SubIdentifier.h>
Public Types | |
| enum | IdentifierType { Invalid, Identifier, IPAddress } |
| Identifier type. More... | |
Public Member Functions | |
| I3SubIdentifier () | |
| Constructor. | |
| void | setIPAddress (const I3IPAddress &address) |
| Sets this identifier as an I3IPAddress. | |
| void | setIdentifier (const I3Identifier &id) |
| Sets this identifier as an I3Identifier. | |
| IdentifierType | getType () const |
| Returns the subidentifier type. | |
| I3IPAddress & | getIPAddress () |
| Returns the IP address. | |
| I3Identifier & | getIdentifier () |
| Returns the identifier. | |
| int | compareTo (const I3SubIdentifier &) const |
| Comparison function. | |
| int | length () const |
Protected Attributes | |
| IdentifierType | type |
| Type of subidentifier. | |
| I3IPAddress | ipAddress |
| IP address referred to. | |
| I3Identifier | identifier |
| Identifier referred to. | |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const I3SubIdentifier &s) |
A wrapper around either an I3IPAddress or an I3Identifier.
The I3 paper proposes an identifier stack that is "a list of identifiers that takes the form (id[1], id[2], ..., id[k]) where where id[i] is either an identifier or an address." To avoid confusion, the former identifier id[i] is called an I3SubIdentifier and the latter is the normal I3Identifier.
Definition at line 37 of file I3SubIdentifier.h.
Identifier type.
| Invalid | |
| Identifier |
Type has not been set yet. |
| IPAddress |
Subidentifier refers to an I3Identifier. Subidentifier refers to an I3IPAddress |
Definition at line 40 of file I3SubIdentifier.h.
| I3SubIdentifier::I3SubIdentifier | ( | ) |
| int I3SubIdentifier::compareTo | ( | const I3SubIdentifier & | id | ) | const |
| I3Identifier & I3SubIdentifier::getIdentifier | ( | ) |
Returns the identifier.
Definition at line 63 of file I3SubIdentifier.cc.
Referenced by I3::handleUDPMessage(), I3::sendPacket(), and I3BaseApp::sendPacket().
| I3IPAddress & I3SubIdentifier::getIPAddress | ( | ) |
Returns the IP address.
Definition at line 55 of file I3SubIdentifier.cc.
Referenced by I3BaseApp::sendPacket(), and I3::sendToNode().
| I3SubIdentifier::IdentifierType I3SubIdentifier::getType | ( | ) | const |
Returns the subidentifier type.
Definition at line 50 of file I3SubIdentifier.cc.
Referenced by I3::handleUDPMessage(), I3::sendPacket(), and I3BaseApp::sendPacket().
| int I3SubIdentifier::length | ( | ) | const |
Definition at line 85 of file I3SubIdentifier.cc.
| void I3SubIdentifier::setIdentifier | ( | const I3Identifier & | id | ) |
Sets this identifier as an I3Identifier.
| id | Identifer to set to |
Definition at line 40 of file I3SubIdentifier.cc.
Referenced by I3IdentifierStack::push().
| void I3SubIdentifier::setIPAddress | ( | const I3IPAddress & | address | ) |
Sets this identifier as an I3IPAddress.
| address | IP address to set to |
Definition at line 33 of file I3SubIdentifier.cc.
Referenced by I3IdentifierStack::push().
|
friend |
Definition at line 90 of file I3SubIdentifier.cc.
|
protected |
Identifier referred to.
Definition at line 90 of file I3SubIdentifier.h.
Referenced by compareTo(), getIdentifier(), length(), operator<<(), setIdentifier(), and setIPAddress().
|
protected |
IP address referred to.
Definition at line 87 of file I3SubIdentifier.h.
Referenced by compareTo(), getIPAddress(), length(), operator<<(), setIdentifier(), and setIPAddress().
|
protected |
Type of subidentifier.
Definition at line 84 of file I3SubIdentifier.h.
Referenced by compareTo(), getIdentifier(), getIPAddress(), getType(), length(), operator<<(), setIdentifier(), and setIPAddress().