A MAC address is used to identify devices on an ethernet network.
More...
#include <opflex/modb/MAC.h>
|
| MAC () |
| Construct a MAC consisting of all zeroes.
|
|
| MAC (const std::string &mac) |
| Construct a MAC using the given string representation. More...
|
|
| MAC (uint8_t mac[6]) |
| Construct a MAC using an array of 6 bytes, in network byte order. More...
|
|
| ~MAC () |
| Destroy the MAC.
|
|
std::string | toString () const |
| Get the MAC represented as a string.
|
|
void | toUIntArray (uint8_t mac[6]) const |
| Get the MAC represented as an array of 6 bytes in network byte order.
|
|
A MAC address is used to identify devices on an ethernet network.
The string representation is a set of 6 hex-encoded bytes separated by colon characters.
opflex::modb::MAC::MAC |
( |
const std::string & |
mac | ) |
|
|
explicit |
Construct a MAC using the given string representation.
- Parameters
-
mac | the string representation of the mac |
- Exceptions
-
std::invalid_argument | if the MAC address is not valid |
opflex::modb::MAC::MAC |
( |
uint8_t |
mac[6] | ) |
|
|
explicit |
Construct a MAC using an array of 6 bytes, in network byte order.
- Parameters
-
mac | the mac represented as an array of 6 bytes |
The documentation for this class was generated from the following file: