#include <MsgAddr.hh>
Public Types | |
| typedef unsigned int | ipaddr_t |
| typedef unsigned short | ipport_t |
| typedef ::sockaddr_in | ipsock_t |
Public Member Functions | |
| ~MsgAddr (void) | |
| MsgAddr (void) | |
| MsgAddr (const ipsock_t &sock) | |
| MsgAddr (const MsgAddr &addr) | |
| MsgAddr (ipaddr_t node, ipport_t port=0, ipport_t subp=0) | |
| MsgAddr & | operator= (const MsgAddr &addr) |
| bool | operator== (const MsgAddr &s) const |
| bool | operator!= (const MsgAddr &s) const |
| ipaddr_t | getIPAddr (void) const |
| ipport_t | getIPPort (void) const |
| ipport_t | getSubProcess (void) const |
| void | getAddr (ipsock_t &sock) const |
| void | setIPAddr (ipaddr_t sock) |
| void | setIPPort (ipport_t port) |
| void | setSubProcess (ipport_t proc) |
| void | setAddr (const ipsock_t &sock) |
| std::string | getIPName (void) const |
Static Public Member Functions | |
| static MsgAddr | findIPHost (const std::string &hostName) |
| typedef unsigned int lmsg::MsgAddr::ipaddr_t |
IP node address data type.
| typedef unsigned short lmsg::MsgAddr::ipport_t |
IP port number data type.
| typedef ::sockaddr_in lmsg::MsgAddr::ipsock_t |
Socket address data type.
| lmsg::MsgAddr::~MsgAddr | ( | void | ) |
Address destructor.
| lmsg::MsgAddr::MsgAddr | ( | void | ) |
An address is constructed and the ip address and all address fields are set to zero. brief Default address constructor.
| lmsg::MsgAddr::MsgAddr | ( | const ipsock_t & | sock | ) |
A message address is constructed and initialized to the IP address and port IDs specified by the argumetn socket address. brief Construct a message address from a socket address.
| sock | IP socket to which the MsgAddr will be initialized. |
| lmsg::MsgAddr::MsgAddr | ( | const MsgAddr & | addr | ) |
A message address is constructed and initialized from another message address. brief copy constructor.
| addr | Address to which the new MsgAddr will be initialized. |
A message address is constructed and initialized from the component quantities. Only the IP node address need be specified. Note that the port address is in host byte ordering! brief Data constructor.
The message address is replaced with a new value. brief Assignment operator.
| addr | New message address. |
| bool lmsg::MsgAddr::operator== | ( | const MsgAddr & | s | ) | const [inline] |
The object is compared with the right hand side value for equality. brief compare for equality
| s | Value to which the address is compared. |
| bool lmsg::MsgAddr::operator!= | ( | const MsgAddr & | s | ) | const [inline] |
The object is compared with the right hand side value for inequality. brief Compare for inequality
| s | Value to which the address is compared. |
| ipaddr_t lmsg::MsgAddr::getIPAddr | ( | void | ) | const |
Fetch the IP node ID. brief Fetch the IP node ID.
| ipport_t lmsg::MsgAddr::getIPPort | ( | void | ) | const |
Fetch the IP port ID. brief Fetch the IP port ID.
| ipport_t lmsg::MsgAddr::getSubProcess | ( | void | ) | const |
Fetch the sub-process number. brief Fetch the subprocess ID.
| void lmsg::MsgAddr::getAddr | ( | ipsock_t & | sock | ) | const |
Get the ip socet name from the message address. brief get the IP address.
| sock | IP socket name structure to receive the socket address. |
| void lmsg::MsgAddr::setIPAddr | ( | ipaddr_t | sock | ) |
Set the IP node number in the message address. brief Set the IP node number.
| sock | IP node number. |
| void lmsg::MsgAddr::setIPPort | ( | ipport_t | port | ) |
Set the IP port number in the message address. brief Set the IP port number.
| port | IP port number. |
| void lmsg::MsgAddr::setSubProcess | ( | ipport_t | proc | ) |
Set the subprocess number in the message address. brief Set the subprocess number.
| proc | subprocess number. |
| void lmsg::MsgAddr::setAddr | ( | const ipsock_t & | sock | ) |
Set the IP fields (node and port) in the message address. brief Set the IP address.
| sock | IP name structure. |
| static MsgAddr lmsg::MsgAddr::findIPHost | ( | const std::string & | hostName | ) | [static] |
Convert a symbolic symbolic IP address in the form "<node-name>:<port>" to a message address. If either the node-name or the port number is not specified, the field is set to zero. brief Conver a symbolic IP address to a MsgAddr.
| hostName | IP host name and port number. |
| std::string lmsg::MsgAddr::getIPName | ( | void | ) | const |
Convert the message address node number to a symbolic value. brief Get the node name.
1.5.4