libutil++  1.9.3
 All Classes Functions Variables
Static Public Member Functions | Static Public Attributes | List of all members
sella::util::Interface Class Reference

Static Public Member Functions

static void setPromiscous (const std::string &interface, bool on=true) throw (InterfaceException)
 
static std::string getInterface (const sella::net::IPAddress &ipAddress, unsigned int ifrFlagMatch=ifrFlagMatchDefault, unsigned int ifrFlagReject=ifrFlagRejectDefault) throw (InterfaceException)
 
static
sella::net::IPAddress::shared_list 
getIPAddresses (const std::string &interface="", unsigned int ifrFlagMatch=ifrFlagMatchDefault, unsigned int ifrFlagReject=ifrFlagRejectDefault) throw (InterfaceException)
 
static sella::net::IPAddress getIPAddress (const std::string &interface, int family=AF_INET) throw (InterfaceException)
 
static std::list< std::string > getNames (unsigned int ifrFlagMatch=ifrFlagMatchDefault, unsigned int ifrFlagReject=ifrFlagRejectDefault) throw (InterfaceException)
 
static std::list< std::string > getEthernetNames (const unsigned int ifrFlagMatch=ifrFlagMatchDefault, const unsigned int ifrFlagReject=ifrFlagRejectDefault) throw (InterfaceException)
 
static std::string getMAC (const std::string &interface) throw (InterfaceException)
 
static std::list< std::string > getMACs (unsigned int ifrFlagMatch=ifrFlagMatchDefault, unsigned int ifrFlagReject=ifrFlagRejectDefault) throw (InterfaceException)
 
static struct in_addr * getAddr (const std::string &interface, struct in_addr *ip) throw (InterfaceException)
 
static unsigned int getIndex (const std::string &interface) throw (InterfaceException)
 
static std::string getName (unsigned int index) throw (InterfaceException)
 
static unsigned char * convertMAC (unsigned char dst[6], const std::string &mac) throw (InterfaceException)
 
static std::string & convertMAC (std::string &dst, const unsigned char mac[6], char delim= ':') throw (InterfaceException)
 
static unsigned char * convertMAC (unsigned char dst[6], const uint64_t mac) throw (InterfaceException)
 
static uint64_t & convertMAC (uint64_t &dst, const unsigned char mac[6]) throw (InterfaceException)
 
static std::string & convertMAC (std::string &dst, const uint64_t mac) throw (InterfaceException)
 
static uint64_t & convertMAC (uint64_t &dst, const std::string &mac) throw (InterfaceException)
 
static bool isEthernet (const std::string &interface) throw (InterfaceException)
 

Static Public Attributes

static const unsigned int ifrFlagMatchDefault = (IFF_UP)
 
static const unsigned int ifrFlagRejectDefault = (IFF_LOOPBACK)
 

Detailed Description

Definition at line 29 of file Interface.h.


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