|
Squid Web Cache master
|
#include <Eui48.h>
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] |
|
inline |
| bool Eui::Eui48::decode | ( | const char * | asc | ) |
Decode an ascii representation of an EUI-48 ethernet address.
| asc | ASCII representation of an ethernet (MAC) address |
| eth | Binary representation of the ethernet address |
| false | Conversion to binary failed. Invalid address |
| true | Conversion completed successfully |
Definition at line 124 of file Eui48.cc.
References clear(), DBG_CRITICAL, debugs, and eui.
Referenced by aclParseArpData().
| bool Eui::Eui48::encode | ( | char * | buf, |
| const int | len | ||
| ) | const |
Encode an ascii representation (asc) of an EUI-48 ethernet address.
| buf | Buffer to receive ASCII representation of an ethernet (MAC) address |
| len | Length of the buffer space available. Must be >= SZ_EUI48_BUF bytes or the encode will fail. |
| eui | Binary representation of the ethernet address |
| false | Conversion to ASCII failed. |
| true | Conversion completed successfully. |
Definition at line 146 of file Eui48.cc.
References debugs, and SZ_EUI48_BUF.
Referenced by Format::Format::assemble().
| const unsigned char * Eui::Eui48::get | ( | void | ) |
| bool Eui::Eui48::lookup | ( | const Ip::Address & | c | ) |
Definition at line 162 of file Eui48.cc.
References DBG_CRITICAL, DBG_IMPORTANT, debugs, FALSE, Ip::Address::getSockAddr(), NULL, Ip::Address::port(), xclose(), xfree, xmalloc, xsocket(), and xstrerr().
Referenced by Comm::TcpAcceptor::acceptInto(), and ACLARP::match().
|
inline |
Definition at line 33 of file Eui48.h.
References eui, and SZ_EUI48_BUF.
|
inline |
Definition at line 32 of file Eui48.h.
References eui, and SZ_EUI48_BUF.
|
inline |
Definition at line 37 of file Eui48.h.
References clear(), eui, and SZ_EUI48_BUF.
|
private |
Definition at line 71 of file Eui48.h.
Referenced by clear(), decode(), operator<(), operator==(), and set().