#include <Eui48.h>

Collaboration diagram for Eui::Eui48:

Public Member Functions

 Eui48 ()
 
bool operator== (const Eui48 &t) const
 
bool operator< (const Eui48 &t) const
 
const unsigned char * get (void)
 
bool set (const char *src, const int len)
 
void clear ()
 
bool decode (const char *asc)
 
bool encode (char *buf, const int len) const
 
bool lookup (const Ip::Address &c)
 

Private Attributes

unsigned char eui [SZ_EUI48_BUF]
 

Detailed Description

Definition at line 27 of file Eui48.h.

Constructor & Destructor Documentation

◆ Eui48()

Eui::Eui48::Eui48 ( )
inline

Definition at line 31 of file Eui48.h.

References clear().

Member Function Documentation

◆ clear()

void Eui::Eui48::clear ( )
inline

Definition at line 44 of file Eui48.h.

References eui, and SZ_EUI48_BUF.

Referenced by Eui48(), decode(), and set().

◆ decode()

bool Eui::Eui48::decode ( const char *  asc)

Decode an ascii representation of an EUI-48 ethernet address.

Parameters
ascASCII representation of an ethernet (MAC) address
ethBinary representation of the ethernet address
Return values
falseConversion to binary failed. Invalid address
trueConversion completed successfully

Definition at line 97 of file Eui48.cc.

References clear(), DBG_CRITICAL, debugs, and eui.

Referenced by aclParseArpData().

◆ encode()

bool Eui::Eui48::encode ( char *  buf,
const int  len 
) const

Encode an ascii representation (asc) of an EUI-48 ethernet address.

Parameters
bufBuffer to receive ASCII representation of an ethernet (MAC) address
lenLength of the buffer space available. Must be >= SZ_EUI48_BUF bytes or the encode will fail.
euiBinary representation of the ethernet address
Return values
falseConversion to ASCII failed.
trueConversion completed successfully.

Definition at line 119 of file Eui48.cc.

References debugs, and SZ_EUI48_BUF.

Referenced by Format::Format::assemble().

◆ get()

const unsigned char * Eui::Eui48::get ( void  )

◆ lookup()

bool Eui::Eui48::lookup ( const Ip::Address c)

◆ operator<()

bool Eui::Eui48::operator< ( const Eui48 t) const
inline

Definition at line 33 of file Eui48.h.

References eui, and SZ_EUI48_BUF.

◆ operator==()

bool Eui::Eui48::operator== ( const Eui48 t) const
inline

Definition at line 32 of file Eui48.h.

References eui, and SZ_EUI48_BUF.

◆ set()

bool Eui::Eui48::set ( const char *  src,
const int  len 
)
inline

Definition at line 37 of file Eui48.h.

References clear(), eui, and SZ_EUI48_BUF.

Member Data Documentation

◆ eui

unsigned char Eui::Eui48::eui[SZ_EUI48_BUF]
private

Definition at line 71 of file Eui48.h.

Referenced by clear(), decode(), operator<(), operator==(), and set().


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

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors