Dibbler - a portable DHCPv6  1.0.2RC1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
TIfaceIface Class Reference

#include <Iface.h>

+ Inheritance diagram for TIfaceIface:
+ Collaboration diagram for TIfaceIface:

Public Member Functions

 TIfaceIface (const char *name, int id, unsigned int flags, char *mac, int maclen, char *llAddr, int llAddrCnt, char *globalAddr, int globalCnt, int hwType)
virtual ~TIfaceIface ()
bool addAddr (SPtr< TIPv6Addr > addr, long pref, long valid, int prefixLen)
void addGlobalAddr (SPtr< TIPv6Addr > addr)
bool addSocket (SPtr< TIPv6Addr > addr, int port, bool ifaceonly, bool reuse)
unsigned int countGlobalAddr ()
int countLLAddress ()
int countSocket ()
bool delAddr (SPtr< TIPv6Addr > addr, int prefixLen)
void delGlobalAddr (SPtr< TIPv6Addr > addr)
bool delSocket (int id)
void firstGlobalAddr ()
char * firstLLAddress ()
void firstSocket ()
bool flagLoopback ()
bool flagMulticast ()
bool flagRunning ()
bool flagUp ()
unsigned int getFlags ()
std::string getFullName ()
SPtr< TIPv6AddrgetGlobalAddr ()
int getHardwareType ()
int getID ()
char * getLLAddress ()
char * getMac ()
int getMacLen ()
bool getMBit ()
 returns M (managed) bit as received from Router Advertisement
char * getName ()
bool getOBit ()
 returns O (other conf) bit as received from Router Advertisement
int getPrefixLength ()
SPtr< TIfaceSocketgetSocket ()
SPtr< TIfaceSocketgetSocketByAddr (SPtr< TIPv6Addr > addr)
SPtr< TIfaceSocketgetSocketByFD (int fd)
void setMBit (bool m)
 set M (managed) bit as received from Router Advertisement
void setOBit (bool o)
 set O (other conf) bit as received from Router Advertisement
void setPrefixLength (int len)
bool updateAddr (SPtr< TIPv6Addr > addr, long pref, long valid)
void updateState (struct iface *x)

Protected Attributes

unsigned int Flags
TContainer< SPtr< TIPv6Addr > > GlobalAddrLst
int HWType
int ID
char * LLAddr
int LLAddrCnt
bool M_bit_
char * Mac
int Maclen
bool O_bit_
int PrefixLen
char * PresLLAddr
TContainer< SPtr< TIfaceSocket > > SocketsLst


std::ostream & operator<< (std::ostream &strum, TIfaceIface &x)

Constructor & Destructor Documentation

TIfaceIface::TIfaceIface ( const char *  name,
int  id,
unsigned int  flags,
char *  mac,
int  maclen,
char *  llAddr,
int  llAddrCnt,
char *  globalAddr,
int  globalCnt,
int  hwType 
TIfaceIface::~TIfaceIface ( )

Member Function Documentation

bool TIfaceIface::addAddr ( SPtr< TIPv6Addr addr,
long  pref,
long  valid,
int  prefixLen 

adds address to this interface with prefered- and valid-lifetime (wrapper around pure C function)

void TIfaceIface::addGlobalAddr ( SPtr< TIPv6Addr addr)
bool TIfaceIface::addSocket ( SPtr< TIPv6Addr addr,
int  port,
bool  ifaceonly,
bool  reuse 
unsigned int TIfaceIface::countGlobalAddr ( )
int TIfaceIface::countLLAddress ( )
int TIfaceIface::countSocket ( )
bool TIfaceIface::delAddr ( SPtr< TIPv6Addr addr,
int  prefixLen 

deletes address from interface (wrapper around pure C function)

void TIfaceIface::delGlobalAddr ( SPtr< TIPv6Addr addr)
bool TIfaceIface::delSocket ( int  id)
void TIfaceIface::firstGlobalAddr ( )
char * TIfaceIface::firstLLAddress ( )

get first link-local address

void TIfaceIface::firstSocket ( )
bool TIfaceIface::flagLoopback ( )

returns true is interface is LOOPBACK

bool TIfaceIface::flagMulticast ( )

returns true is interface is MULTICAST capable

bool TIfaceIface::flagRunning ( )

returns true if interface is RUNNING

bool TIfaceIface::flagUp ( )

returns true if interface is UP

unsigned int TIfaceIface::getFlags ( )
string TIfaceIface::getFullName ( void  )
SPtr< TIPv6Addr > TIfaceIface::getGlobalAddr ( )
int TIfaceIface::getHardwareType ( )

returns HW type

int TIfaceIface::getID ( void  )
char * TIfaceIface::getLLAddress ( )

get next link-local address (oh boy, this method stinks. Nobody uses it, anyway)

char * TIfaceIface::getMac ( )

returns MAC

int TIfaceIface::getMacLen ( )

returns MAC length

bool TIfaceIface::getMBit ( )

returns M (managed) bit as received from Router Advertisement

value of M bit
char * TIfaceIface::getName ( void  )
bool TIfaceIface::getOBit ( )

returns O (other conf) bit as received from Router Advertisement

value of O bit
int TIfaceIface::getPrefixLength ( )
SPtr< TIfaceSocket > TIfaceIface::getSocket ( )
SPtr< TIfaceSocket > TIfaceIface::getSocketByAddr ( SPtr< TIPv6Addr addr)
SPtr< TIfaceSocket > TIfaceIface::getSocketByFD ( int  fd)
void TIfaceIface::setMBit ( bool  m)

set M (managed) bit as received from Router Advertisement

mbool flag (Sets of clears M bit)
void TIfaceIface::setOBit ( bool  o)

set O (other conf) bit as received from Router Advertisement

obool flag (Sets of clears O bit)
void TIfaceIface::setPrefixLength ( int  len)
bool TIfaceIface::updateAddr ( SPtr< TIPv6Addr addr,
long  pref,
long  valid 

update address prefered- and valid-lifetime

void TIfaceIface::updateState ( struct iface x)

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  strum,
TIfaceIface x 

Member Data Documentation

unsigned int TIfaceIface::Flags
TContainer< SPtr<TIPv6Addr> > TIfaceIface::GlobalAddrLst
int TIfaceIface::HWType
int TIfaceIface::ID
char* TIfaceIface::LLAddr
int TIfaceIface::LLAddrCnt
bool TIfaceIface::M_bit_
char* TIfaceIface::Mac
int TIfaceIface::Maclen
char TIfaceIface::Name[MAX_IFNAME_LENGTH]
bool TIfaceIface::O_bit_
int TIfaceIface::PrefixLen
char* TIfaceIface::PresLLAddr
TContainer< SPtr<TIfaceSocket> > TIfaceIface::SocketsLst

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