IPAddress Class Reference

#include <ip-address.h>

Inheritance diagram for IPAddress:

Inheritance graph
[legend]
Collaboration diagram for IPAddress:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 IPAddress ()
 IPAddress (const char *ip)
virtual ~IPAddress ()
virtual int INT (char *str=0)
virtual int AND (char *str1, char *str2=0)
virtual int OR (char *str1, char *str2=0)
virtual int command (int argc, const char *const *argv)
virtual int toString (char *str, int strlen)
virtual int strlen ()
virtual void setAddress (const char *addr)

Private Attributes

int ipAddr_

Detailed Description

IPv4 Miracle Address class

Definition at line 38 of file ip-address.h.


Member Function Documentation

int IPAddress::command ( int  argc,
const char *const *  argv 
) [virtual]

TCL command interpreter. It implements the following OTcl methods:

Parameters:
argc number of arguments in argv
argv array of strings which are the comand parameters (Note that argv[0] is the name of the object)
Returns:
TCL_OK or TCL_ERROR whether the command has been dispatched succesfully or no
See also:
Module

Reimplemented from MrclAddress.

Definition at line 116 of file ip-address.cc.

References MrclAddress::command().

Here is the call graph for this function:

int IPAddress::toString ( char *  str,
int  strlen 
) [virtual]

Convert the Address to a string and write it into the str buffer.

Parameters:
str Buffer into which will be written the address
strlen Length of str
Returns:
0 if the buffer is smaller than converted string address, 1 otherwise

Implements MrclAddress.

Definition at line 69 of file ip-address.cc.

References MrclAddress::getAddr(), and strlen().

Referenced by MrclRoutingStatic::command().

Here is the call graph for this function:

int IPAddress::strlen (  )  [virtual]

Returns:
The length, in number of char, of the address converted to string

Implements MrclAddress.

Definition at line 81 of file ip-address.cc.

References MrclAddress::getAddr().

Referenced by MrclRoutingStatic::command(), and toString().

Here is the call graph for this function:

void IPAddress::setAddress ( const char *  addr  )  [virtual]

Set the address converting the null terminated string.

Parameters:
addr Null terminated string which represent the address

Implements MrclAddress.

Definition at line 90 of file ip-address.cc.

References ipAddr_, and MrclAddress::setAddr().

Referenced by IPAddress().

Here is the call graph for this function:


The documentation for this class was generated from the following files:
Generated on Wed Nov 26 15:48:45 2008 for NS-MIRACLE library by  doxygen 1.5.2