The Pedigree Project  0.1
Public Types | Public Member Functions | Private Attributes | List of all members
Pedigree::IpAddress Class Reference
+ Collaboration diagram for Pedigree::IpAddress:

Public Types

enum  IpType { IPv4 = 0, IPv6 }
 

Public Member Functions

 IpAddress ()
 
 IpAddress (IpType type)
 
 IpAddress (uint32_t ipv4)
 
 IpAddress (uint8_t *ipv6)
 
void setIp (uint32_t ipv4)
 
void setIp (uint8_t *ipv6)
 
uint32_t getIp ()
 
void getIp (uint8_t *ipv6)
 
IpType getType ()
 
IpAddressoperator= (IpAddress a)
 
IpAddressoperator= (uint32_t a)
 
bool operator== (IpAddress a)
 
bool operator== (uint32_t a)
 
string toString ()
 

Private Attributes

IpType m_Type
 
uint32_t m_Ipv4
 
uint8_t m_Ipv6 [16]
 
bool m_bSet
 

Detailed Description

An IPv4/IPv6 address

Definition at line 44 of file user/applications/netconfig/main.cc.

Member Enumeration Documentation

The type of an IP address

Definition at line 48 of file user/applications/netconfig/main.cc.

Constructor & Destructor Documentation

Pedigree::IpAddress::IpAddress ( )
inline

Constructors

Definition at line 55 of file user/applications/netconfig/main.cc.

Member Function Documentation

uint32_t Pedigree::IpAddress::getIp ( )
inline

IP getters

Definition at line 84 of file user/applications/netconfig/main.cc.

Referenced by operator=().

+ Here is the caller graph for this function:

IpType Pedigree::IpAddress::getType ( )
inline

Type getter

Definition at line 97 of file user/applications/netconfig/main.cc.

Referenced by operator=().

+ Here is the caller graph for this function:

IpAddress& Pedigree::IpAddress::operator= ( IpAddress  a)
inline

Operators

Definition at line 104 of file user/applications/netconfig/main.cc.

References getIp(), getType(), and operator==().

void Pedigree::IpAddress::setIp ( uint32_t  ipv4)
inline

IP setters - only one type is valid at any one point in time

Definition at line 66 of file user/applications/netconfig/main.cc.

string Pedigree::IpAddress::toString ( )
inline
Todo:
IPv6

Definition at line 143 of file user/applications/netconfig/main.cc.


The documentation for this class was generated from the following file: