\hypertarget{classMac}{
\section{Mac Class Reference}
\label{classMac}\index{Mac@{Mac}}
}


IEEE standard 48-\/bit address.  




{\ttfamily \#include $<$mac.hh$>$}

\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classMac_af6550e2d704d374ad07a35f80d6df82e}{
\hyperlink{classMac_af6550e2d704d374ad07a35f80d6df82e}{Mac} ()}
\label{classMac_af6550e2d704d374ad07a35f80d6df82e}

\begin{DoxyCompactList}\small\item\em Default constructor. \item\end{DoxyCompactList}\item 
\hyperlink{classMac_aa7f641d9c5e83a573063cd928f944004}{Mac} (const uint8\_\-t $\ast$from\_\-uint8)
\begin{DoxyCompactList}\small\item\em Constructor from a (uint8\_\-t $\ast$) memory pointer. \item\end{DoxyCompactList}\item 
\hyperlink{classMac_a41b5f5ba2eea8e89251658d5b97ac5f6}{Mac} (const char $\ast$from\_\-cstring)  throw (InvalidString)
\begin{DoxyCompactList}\small\item\em Constructor from a string. \item\end{DoxyCompactList}\item 
\hyperlink{classMac_a3831997fc636e4d23eef77f0049b6be4}{Mac} (const struct \hyperlink{structether__addr}{ether\_\-addr} \&from\_\-ether\_\-addr)
\begin{DoxyCompactList}\small\item\em Constructor from \hyperlink{structether__addr}{ether\_\-addr} structure. \item\end{DoxyCompactList}\item 
\hyperlink{classMac_afd66255cc2971aaab2401e24c36c7614}{Mac} (const struct sockaddr \&from\_\-sockaddr)
\begin{DoxyCompactList}\small\item\em Constructor from sockaddr structure. \item\end{DoxyCompactList}\item 
size\_\-t \hyperlink{classMac_a8c5fa3577ac942c8958b1a24158e7be1}{copy\_\-out} (uint8\_\-t $\ast$to\_\-uint8) const 
\begin{DoxyCompactList}\small\item\em Copy \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} raw address to specified memory location. \item\end{DoxyCompactList}\item 
size\_\-t \hyperlink{classMac_a5f0ed9daf47d858a9c866ac55706c906}{copy\_\-out} (struct \hyperlink{structether__addr}{ether\_\-addr} \&to\_\-ether\_\-addr) const 
\begin{DoxyCompactList}\small\item\em Copy \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} raw address to \hyperlink{structether__addr}{ether\_\-addr} structure. \item\end{DoxyCompactList}\item 
size\_\-t \hyperlink{classMac_a19745548bbfa4588e91bb576beb35601}{copy\_\-out} (struct sockaddr \&to\_\-sockaddr) const 
\begin{DoxyCompactList}\small\item\em Copy \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} raw address to sockaddr structure. \item\end{DoxyCompactList}\item 
size\_\-t \hyperlink{classMac_ab32438bbfa18a56cae9a46da2d56464f}{copy\_\-in} (const uint8\_\-t $\ast$from\_\-uint8)
\begin{DoxyCompactList}\small\item\em Copy a raw \hyperlink{classMac}{Mac} address from specified memory location into \hyperlink{classMac}{Mac} container. \item\end{DoxyCompactList}\item 
size\_\-t \hyperlink{classMac_af9ab705811c64e6c8a79d65d65fc1e85}{copy\_\-in} (const struct \hyperlink{structether__addr}{ether\_\-addr} \&from\_\-ether\_\-addr)
\begin{DoxyCompactList}\small\item\em Copy a raw \hyperlink{classMac}{Mac} address from \hyperlink{structether__addr}{ether\_\-addr} structure into \hyperlink{classMac}{Mac} container. \item\end{DoxyCompactList}\item 
size\_\-t \hyperlink{classMac_a3d5e6e95f6fa83b88116c704cee1860b}{copy\_\-in} (const struct sockaddr \&from\_\-sockaddr)
\begin{DoxyCompactList}\small\item\em Copy a raw \hyperlink{classMac}{Mac} address from sockaddr structure into \hyperlink{classMac}{Mac} container. \item\end{DoxyCompactList}\item 
size\_\-t \hyperlink{classMac_a518eac5f6686e354b4b6019d0beed216}{copy\_\-in} (const char $\ast$from\_\-cstring)  throw (InvalidString)
\begin{DoxyCompactList}\small\item\em Copy a \hyperlink{classMac}{Mac} address from a string. \item\end{DoxyCompactList}\item 
bool \hyperlink{classMac_ae771e64791be4f58d42178a1fe604b7d}{operator$<$} (const \hyperlink{classMac}{Mac} \&other) const 
\begin{DoxyCompactList}\small\item\em Less-\/Than Operator. \item\end{DoxyCompactList}\item 
bool \hyperlink{classMac_a99116565802eaeeac4722e65a8d47e4f}{operator==} (const \hyperlink{classMac}{Mac} \&other) const 
\begin{DoxyCompactList}\small\item\em Equality Operator. \item\end{DoxyCompactList}\item 
bool \hyperlink{classMac_a867ea049e1a080d6a8334cb6fbe3af71}{operator!=} (const \hyperlink{classMac}{Mac} \&other) const 
\begin{DoxyCompactList}\small\item\em Not-\/Equal Operator. \item\end{DoxyCompactList}\item 
string \hyperlink{classMac_a99cd36f5258c409559d008e85a1c4a29}{str} () const 
\begin{DoxyCompactList}\small\item\em Convert this address from binary form to presentation format. \item\end{DoxyCompactList}\item 
const uint8\_\-t $\ast$ \hyperlink{classMac_a6cb9c5a258d04a88718cdfef0e498774}{addr} () const 
\begin{DoxyCompactList}\small\item\em Get \hyperlink{protocolthe-p}{the} raw value of this address. \item\end{DoxyCompactList}\item 
bool \hyperlink{classMac_a0ddd5d2cc683121de1d98e98fdf996f7}{is\_\-zero} () const 
\begin{DoxyCompactList}\small\item\em Test if this address is numerically zero. \item\end{DoxyCompactList}\item 
bool \hyperlink{classMac_ab28f7b65b59e7958cab2352e017485a8}{is\_\-unicast} () const 
\begin{DoxyCompactList}\small\item\em Test if this address is a valid unicast address. \item\end{DoxyCompactList}\item 
bool \hyperlink{classMac_a4a188de5e386e03da256adf13c483018}{is\_\-multicast} () const 
\begin{DoxyCompactList}\small\item\em Test if this address is a valid multicast address. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
static size\_\-t \hyperlink{classMac_a1b31a113d794a765753bef66cd1be333}{addr\_\-bytelen} ()
\begin{DoxyCompactList}\small\item\em Get \hyperlink{protocolthe-p}{the} size of \hyperlink{protocolthe-p}{the} raw \hyperlink{classMac}{Mac} address (in octets). \item\end{DoxyCompactList}\item 
static uint32\_\-t \hyperlink{classMac_a2c8bcedb817e0418b4edc0a87312ecf7}{addr\_\-bitlen} ()
\begin{DoxyCompactList}\small\item\em Get \hyperlink{protocolthe-p}{the} size of \hyperlink{protocolthe-p}{the} raw \hyperlink{classMac}{Mac} address (in number of bits). \item\end{DoxyCompactList}\item 
\hypertarget{classMac_a7415937eb78a8f0d3ea20698ab3adb70}{
static const \hyperlink{classMac}{Mac} \& \hyperlink{classMac_a7415937eb78a8f0d3ea20698ab3adb70}{ZERO} ()}
\label{classMac_a7415937eb78a8f0d3ea20698ab3adb70}

\begin{DoxyCompactList}\small\item\em Pre-\/defined \hyperlink{classMac}{Mac} address constants. \item\end{DoxyCompactList}\item 
\hypertarget{classMac_a12eba476ed4601b4ae6a613de567c903}{
static const \hyperlink{classMac}{Mac} \& {\bfseries ALL\_\-ONES} ()}
\label{classMac_a12eba476ed4601b4ae6a613de567c903}

\item 
\hypertarget{classMac_a757f93a46b53f717eccafdbcea485a63}{
static const \hyperlink{classMac}{Mac} \& {\bfseries BROADCAST} ()}
\label{classMac_a757f93a46b53f717eccafdbcea485a63}

\item 
\hypertarget{classMac_ac2fbe5cc16c5c109fb04047b4c03a117}{
static const \hyperlink{classMac}{Mac} \& {\bfseries STP\_\-MULTICAST} ()}
\label{classMac_ac2fbe5cc16c5c109fb04047b4c03a117}

\item 
\hypertarget{classMac_a57a4c9e04e1eb9a7cd559d4bc864ee77}{
static const \hyperlink{classMac}{Mac} \& {\bfseries LLDP\_\-MULTICAST} ()}
\label{classMac_a57a4c9e04e1eb9a7cd559d4bc864ee77}

\item 
\hypertarget{classMac_a332b68c7381f7d4ff77e930bbc0cfd1d}{
static const \hyperlink{classMac}{Mac} \& {\bfseries GMRP\_\-MULTICAST} ()}
\label{classMac_a332b68c7381f7d4ff77e930bbc0cfd1d}

\item 
\hypertarget{classMac_a978f392a2936f3a62825e9704e6a5f03}{
static const \hyperlink{classMac}{Mac} \& {\bfseries GVRP\_\-MULTICAST} ()}
\label{classMac_a978f392a2936f3a62825e9704e6a5f03}

\end{DoxyCompactItemize}
\subsection*{Static Public Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classMac_a65b700455e96132a144bb533523d0126}{
static const uint32\_\-t \hyperlink{classMac_a65b700455e96132a144bb533523d0126}{ADDR\_\-BITLEN} = 48}
\label{classMac_a65b700455e96132a144bb533523d0126}

\begin{DoxyCompactList}\small\item\em Number of bits in address as a constant. \item\end{DoxyCompactList}\item 
\hypertarget{classMac_a71d95a104549daba41dc53e26cfc4c93}{
static const uint32\_\-t \hyperlink{classMac_a71d95a104549daba41dc53e26cfc4c93}{ADDR\_\-BYTELEN} = \hyperlink{classMac_a65b700455e96132a144bb533523d0126}{ADDR\_\-BITLEN} / 8}
\label{classMac_a71d95a104549daba41dc53e26cfc4c93}

\begin{DoxyCompactList}\small\item\em Number of bytes in address as a constant. \item\end{DoxyCompactList}\item 
\hypertarget{classMac_a403781c3c85a3f5ddf861097ca57f535}{
static const uint8\_\-t \hyperlink{classMac_a403781c3c85a3f5ddf861097ca57f535}{MULTICAST\_\-BIT} = 0x1}
\label{classMac_a403781c3c85a3f5ddf861097ca57f535}

\begin{DoxyCompactList}\small\item\em The multicast bit in \hyperlink{protocolthe-p}{the} first octet of \hyperlink{protocolthe-p}{the} address. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classMac_aaf39319434ab8edc3a09146fa15235dc}{
uint8\_\-t {\bfseries \_\-addr} \mbox{[}\hyperlink{classMac_a71d95a104549daba41dc53e26cfc4c93}{ADDR\_\-BYTELEN}\mbox{]}}
\label{classMac_aaf39319434ab8edc3a09146fa15235dc}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
IEEE standard 48-\/bit address. 

\subsection{Constructor \& Destructor Documentation}
\hypertarget{classMac_aa7f641d9c5e83a573063cd928f944004}{
\index{Mac@{Mac}!Mac@{Mac}}
\index{Mac@{Mac}!Mac@{Mac}}
\subsubsection[{Mac}]{\setlength{\rightskip}{0pt plus 5cm}Mac::Mac (
\begin{DoxyParamCaption}
\item[{const uint8\_\-t $\ast$}]{from\_\-uint8}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}explicit\mbox{]}}}}
\label{classMac_aa7f641d9c5e83a573063cd928f944004}


Constructor from a (uint8\_\-t $\ast$) memory pointer. 


\begin{DoxyParams}{Parameters}
{\em from\_\-uint8} & \hyperlink{protocolthe-p}{the} pointer to \hyperlink{protocolthe-p}{the} memory to copy \hyperlink{protocolthe-p}{the} address value from. \\
\hline
\end{DoxyParams}
\hypertarget{classMac_a41b5f5ba2eea8e89251658d5b97ac5f6}{
\index{Mac@{Mac}!Mac@{Mac}}
\index{Mac@{Mac}!Mac@{Mac}}
\subsubsection[{Mac}]{\setlength{\rightskip}{0pt plus 5cm}Mac::Mac (
\begin{DoxyParamCaption}
\item[{const char $\ast$}]{from\_\-cstring}
\end{DoxyParamCaption}
)  throw ({\bf InvalidString})}}
\label{classMac_a41b5f5ba2eea8e89251658d5b97ac5f6}


Constructor from a string. 


\begin{DoxyParams}{Parameters}
{\em from\_\-cstring} & C-\/style string of \hyperlink{protocolthe-p}{the} form XX:XX:XX:XX:XX:XX where X represents a hex-\/digit. \\
\hline
\end{DoxyParams}

\begin{DoxyExceptions}{Exceptions}
{\em \hyperlink{classInvalidString}{InvalidString}} & if string passed does not match expected format. \\
\hline
\end{DoxyExceptions}
\hypertarget{classMac_a3831997fc636e4d23eef77f0049b6be4}{
\index{Mac@{Mac}!Mac@{Mac}}
\index{Mac@{Mac}!Mac@{Mac}}
\subsubsection[{Mac}]{\setlength{\rightskip}{0pt plus 5cm}Mac::Mac (
\begin{DoxyParamCaption}
\item[{const struct {\bf ether\_\-addr} \&}]{from\_\-ether\_\-addr}
\end{DoxyParamCaption}
)}}
\label{classMac_a3831997fc636e4d23eef77f0049b6be4}


Constructor from \hyperlink{structether__addr}{ether\_\-addr} structure. 


\begin{DoxyParams}{Parameters}
{\em from\_\-ether\_\-addr} & \hyperlink{protocolthe-p}{the} \hyperlink{structether__addr}{ether\_\-addr} structure to construct \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} address from. \\
\hline
\end{DoxyParams}
\hypertarget{classMac_afd66255cc2971aaab2401e24c36c7614}{
\index{Mac@{Mac}!Mac@{Mac}}
\index{Mac@{Mac}!Mac@{Mac}}
\subsubsection[{Mac}]{\setlength{\rightskip}{0pt plus 5cm}Mac::Mac (
\begin{DoxyParamCaption}
\item[{const struct sockaddr \&}]{from\_\-sockaddr}
\end{DoxyParamCaption}
)}}
\label{classMac_afd66255cc2971aaab2401e24c36c7614}


Constructor from sockaddr structure. 


\begin{DoxyParams}{Parameters}
{\em from\_\-sockaddr} & \hyperlink{protocolthe-p}{the} sockaddr structure to construct \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} address from. \\
\hline
\end{DoxyParams}


\subsection{Member Function Documentation}
\hypertarget{classMac_a6cb9c5a258d04a88718cdfef0e498774}{
\index{Mac@{Mac}!addr@{addr}}
\index{addr@{addr}!Mac@{Mac}}
\subsubsection[{addr}]{\setlength{\rightskip}{0pt plus 5cm}const uint8\_\-t$\ast$ Mac::addr (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classMac_a6cb9c5a258d04a88718cdfef0e498774}


Get \hyperlink{protocolthe-p}{the} raw value of this address. 

\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} value of this MAC address as a pointer to an array of unsigned bytes. 
\end{DoxyReturn}
\hypertarget{classMac_a2c8bcedb817e0418b4edc0a87312ecf7}{
\index{Mac@{Mac}!addr\_\-bitlen@{addr\_\-bitlen}}
\index{addr\_\-bitlen@{addr\_\-bitlen}!Mac@{Mac}}
\subsubsection[{addr\_\-bitlen}]{\setlength{\rightskip}{0pt plus 5cm}static uint32\_\-t Mac::addr\_\-bitlen (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline, static\mbox{]}}}}
\label{classMac_a2c8bcedb817e0418b4edc0a87312ecf7}


Get \hyperlink{protocolthe-p}{the} size of \hyperlink{protocolthe-p}{the} raw \hyperlink{classMac}{Mac} address (in number of bits). 

\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} size of \hyperlink{protocolthe-p}{the} raw \hyperlink{classMac}{Mac} address (in number of bits). 
\end{DoxyReturn}
\hypertarget{classMac_a1b31a113d794a765753bef66cd1be333}{
\index{Mac@{Mac}!addr\_\-bytelen@{addr\_\-bytelen}}
\index{addr\_\-bytelen@{addr\_\-bytelen}!Mac@{Mac}}
\subsubsection[{addr\_\-bytelen}]{\setlength{\rightskip}{0pt plus 5cm}static size\_\-t Mac::addr\_\-bytelen (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline, static\mbox{]}}}}
\label{classMac_a1b31a113d794a765753bef66cd1be333}


Get \hyperlink{protocolthe-p}{the} size of \hyperlink{protocolthe-p}{the} raw \hyperlink{classMac}{Mac} address (in octets). 

\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} size of \hyperlink{protocolthe-p}{the} raw \hyperlink{classMac}{Mac} address (in octets). 
\end{DoxyReturn}
\hypertarget{classMac_af9ab705811c64e6c8a79d65d65fc1e85}{
\index{Mac@{Mac}!copy\_\-in@{copy\_\-in}}
\index{copy\_\-in@{copy\_\-in}!Mac@{Mac}}
\subsubsection[{copy\_\-in}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t Mac::copy\_\-in (
\begin{DoxyParamCaption}
\item[{const struct {\bf ether\_\-addr} \&}]{from\_\-ether\_\-addr}
\end{DoxyParamCaption}
)}}
\label{classMac_af9ab705811c64e6c8a79d65d65fc1e85}


Copy a raw \hyperlink{classMac}{Mac} address from \hyperlink{structether__addr}{ether\_\-addr} structure into \hyperlink{classMac}{Mac} container. 


\begin{DoxyParams}{Parameters}
{\em from\_\-ether\_\-addr} & \hyperlink{protocolthe-p}{the} storage to copy \hyperlink{protocolthe-p}{the} address from. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} number of copied octets. 
\end{DoxyReturn}
\hypertarget{classMac_ab32438bbfa18a56cae9a46da2d56464f}{
\index{Mac@{Mac}!copy\_\-in@{copy\_\-in}}
\index{copy\_\-in@{copy\_\-in}!Mac@{Mac}}
\subsubsection[{copy\_\-in}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t Mac::copy\_\-in (
\begin{DoxyParamCaption}
\item[{const uint8\_\-t $\ast$}]{from\_\-uint8}
\end{DoxyParamCaption}
)}}
\label{classMac_ab32438bbfa18a56cae9a46da2d56464f}


Copy a raw \hyperlink{classMac}{Mac} address from specified memory location into \hyperlink{classMac}{Mac} container. 


\begin{DoxyParams}{Parameters}
{\em from\_\-uint8} & \hyperlink{protocolthe-p}{the} memory address to copy \hyperlink{protocolthe-p}{the} address from. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} number of copied octets. 
\end{DoxyReturn}
\hypertarget{classMac_a3d5e6e95f6fa83b88116c704cee1860b}{
\index{Mac@{Mac}!copy\_\-in@{copy\_\-in}}
\index{copy\_\-in@{copy\_\-in}!Mac@{Mac}}
\subsubsection[{copy\_\-in}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t Mac::copy\_\-in (
\begin{DoxyParamCaption}
\item[{const struct sockaddr \&}]{from\_\-sockaddr}
\end{DoxyParamCaption}
)}}
\label{classMac_a3d5e6e95f6fa83b88116c704cee1860b}


Copy a raw \hyperlink{classMac}{Mac} address from sockaddr structure into \hyperlink{classMac}{Mac} container. 


\begin{DoxyParams}{Parameters}
{\em from\_\-sockaddr} & \hyperlink{protocolthe-p}{the} storage to copy \hyperlink{protocolthe-p}{the} address from. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} number of copied octets. 
\end{DoxyReturn}
\hypertarget{classMac_a518eac5f6686e354b4b6019d0beed216}{
\index{Mac@{Mac}!copy\_\-in@{copy\_\-in}}
\index{copy\_\-in@{copy\_\-in}!Mac@{Mac}}
\subsubsection[{copy\_\-in}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t Mac::copy\_\-in (
\begin{DoxyParamCaption}
\item[{const char $\ast$}]{from\_\-cstring}
\end{DoxyParamCaption}
)  throw ({\bf InvalidString})}}
\label{classMac_a518eac5f6686e354b4b6019d0beed216}


Copy a \hyperlink{classMac}{Mac} address from a string. 


\begin{DoxyParams}{Parameters}
{\em from\_\-cstring} & C-\/style string of \hyperlink{protocolthe-p}{the} form XX:XX:XX:XX:XX:XX where X represents a hex-\/digit. \\
\hline
\end{DoxyParams}

\begin{DoxyExceptions}{Exceptions}
{\em \hyperlink{classInvalidString}{InvalidString}} & if string passed does not match expected format. \\
\hline
\end{DoxyExceptions}
\hypertarget{classMac_a5f0ed9daf47d858a9c866ac55706c906}{
\index{Mac@{Mac}!copy\_\-out@{copy\_\-out}}
\index{copy\_\-out@{copy\_\-out}!Mac@{Mac}}
\subsubsection[{copy\_\-out}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t Mac::copy\_\-out (
\begin{DoxyParamCaption}
\item[{struct {\bf ether\_\-addr} \&}]{to\_\-ether\_\-addr}
\end{DoxyParamCaption}
) const}}
\label{classMac_a5f0ed9daf47d858a9c866ac55706c906}


Copy \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} raw address to \hyperlink{structether__addr}{ether\_\-addr} structure. 


\begin{DoxyParams}{Parameters}
{\em to\_\-ether\_\-addr} & \hyperlink{protocolthe-p}{the} storage to copy \hyperlink{protocolthe-p}{the} address to. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} number of copied octets. 
\end{DoxyReturn}
\hypertarget{classMac_a8c5fa3577ac942c8958b1a24158e7be1}{
\index{Mac@{Mac}!copy\_\-out@{copy\_\-out}}
\index{copy\_\-out@{copy\_\-out}!Mac@{Mac}}
\subsubsection[{copy\_\-out}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t Mac::copy\_\-out (
\begin{DoxyParamCaption}
\item[{uint8\_\-t $\ast$}]{to\_\-uint8}
\end{DoxyParamCaption}
) const}}
\label{classMac_a8c5fa3577ac942c8958b1a24158e7be1}


Copy \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} raw address to specified memory location. 


\begin{DoxyParams}{Parameters}
{\em } & to\_\-uint8 \hyperlink{protocolthe-p}{the} pointer to \hyperlink{protocolthe-p}{the} memory to copy \hyperlink{protocolthe-p}{the} address to. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} number of copied octets. 
\end{DoxyReturn}
\hypertarget{classMac_a19745548bbfa4588e91bb576beb35601}{
\index{Mac@{Mac}!copy\_\-out@{copy\_\-out}}
\index{copy\_\-out@{copy\_\-out}!Mac@{Mac}}
\subsubsection[{copy\_\-out}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t Mac::copy\_\-out (
\begin{DoxyParamCaption}
\item[{struct sockaddr \&}]{to\_\-sockaddr}
\end{DoxyParamCaption}
) const}}
\label{classMac_a19745548bbfa4588e91bb576beb35601}


Copy \hyperlink{protocolthe-p}{the} \hyperlink{classMac}{Mac} raw address to sockaddr structure. 


\begin{DoxyParams}{Parameters}
{\em to\_\-sockaddr} & \hyperlink{protocolthe-p}{the} storage to copy \hyperlink{protocolthe-p}{the} address to. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} number of copied octets. 
\end{DoxyReturn}
\hypertarget{classMac_a4a188de5e386e03da256adf13c483018}{
\index{Mac@{Mac}!is\_\-multicast@{is\_\-multicast}}
\index{is\_\-multicast@{is\_\-multicast}!Mac@{Mac}}
\subsubsection[{is\_\-multicast}]{\setlength{\rightskip}{0pt plus 5cm}bool Mac::is\_\-multicast (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const}}
\label{classMac_a4a188de5e386e03da256adf13c483018}


Test if this address is a valid multicast address. 

\begin{DoxyReturn}{Returns}
true if \hyperlink{protocolthe-p}{the} address is a valid multicast address. 
\end{DoxyReturn}
\hypertarget{classMac_ab28f7b65b59e7958cab2352e017485a8}{
\index{Mac@{Mac}!is\_\-unicast@{is\_\-unicast}}
\index{is\_\-unicast@{is\_\-unicast}!Mac@{Mac}}
\subsubsection[{is\_\-unicast}]{\setlength{\rightskip}{0pt plus 5cm}bool Mac::is\_\-unicast (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const}}
\label{classMac_ab28f7b65b59e7958cab2352e017485a8}


Test if this address is a valid unicast address. 

\begin{DoxyReturn}{Returns}
true if \hyperlink{protocolthe-p}{the} address is a valid unicast address. 
\end{DoxyReturn}
\hypertarget{classMac_a0ddd5d2cc683121de1d98e98fdf996f7}{
\index{Mac@{Mac}!is\_\-zero@{is\_\-zero}}
\index{is\_\-zero@{is\_\-zero}!Mac@{Mac}}
\subsubsection[{is\_\-zero}]{\setlength{\rightskip}{0pt plus 5cm}bool Mac::is\_\-zero (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classMac_a0ddd5d2cc683121de1d98e98fdf996f7}


Test if this address is numerically zero. 

\begin{DoxyReturn}{Returns}
true if \hyperlink{protocolthe-p}{the} address is numerically zero. 
\end{DoxyReturn}
\hypertarget{classMac_a867ea049e1a080d6a8334cb6fbe3af71}{
\index{Mac@{Mac}!operator!=@{operator!=}}
\index{operator!=@{operator!=}!Mac@{Mac}}
\subsubsection[{operator!=}]{\setlength{\rightskip}{0pt plus 5cm}bool Mac::operator!= (
\begin{DoxyParamCaption}
\item[{const {\bf Mac} \&}]{other}
\end{DoxyParamCaption}
) const}}
\label{classMac_a867ea049e1a080d6a8334cb6fbe3af71}


Not-\/Equal Operator. 


\begin{DoxyParams}{Parameters}
{\em other} & \hyperlink{protocolthe-p}{the} right-\/hand operand to compare against. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
true if \hyperlink{protocolthe-p}{the} left-\/hand operand is numerically not same as \hyperlink{protocolthe-p}{the} right-\/hand operand. 
\end{DoxyReturn}
\hypertarget{classMac_ae771e64791be4f58d42178a1fe604b7d}{
\index{Mac@{Mac}!operator$<$@{operator$<$}}
\index{operator$<$@{operator$<$}!Mac@{Mac}}
\subsubsection[{operator$<$}]{\setlength{\rightskip}{0pt plus 5cm}bool Mac::operator$<$ (
\begin{DoxyParamCaption}
\item[{const {\bf Mac} \&}]{other}
\end{DoxyParamCaption}
) const}}
\label{classMac_ae771e64791be4f58d42178a1fe604b7d}


Less-\/Than Operator. 


\begin{DoxyParams}{Parameters}
{\em other} & \hyperlink{protocolthe-p}{the} right-\/hand operand to compare against. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
true if \hyperlink{protocolthe-p}{the} left-\/hand operand is numerically smaller than \hyperlink{protocolthe-p}{the} right-\/hand operand. 
\end{DoxyReturn}
\hypertarget{classMac_a99116565802eaeeac4722e65a8d47e4f}{
\index{Mac@{Mac}!operator==@{operator==}}
\index{operator==@{operator==}!Mac@{Mac}}
\subsubsection[{operator==}]{\setlength{\rightskip}{0pt plus 5cm}bool Mac::operator== (
\begin{DoxyParamCaption}
\item[{const {\bf Mac} \&}]{other}
\end{DoxyParamCaption}
) const}}
\label{classMac_a99116565802eaeeac4722e65a8d47e4f}


Equality Operator. 


\begin{DoxyParams}{Parameters}
{\em other} & \hyperlink{protocolthe-p}{the} right-\/hand operand to compare against. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
true if \hyperlink{protocolthe-p}{the} left-\/hand operand is numerically same as \hyperlink{protocolthe-p}{the} right-\/hand operand. 
\end{DoxyReturn}
\hypertarget{classMac_a99cd36f5258c409559d008e85a1c4a29}{
\index{Mac@{Mac}!str@{str}}
\index{str@{str}!Mac@{Mac}}
\subsubsection[{str}]{\setlength{\rightskip}{0pt plus 5cm}string Mac::str (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const}}
\label{classMac_a99cd36f5258c409559d008e85a1c4a29}


Convert this address from binary form to presentation format. 

\begin{DoxyReturn}{Returns}
C++ string with \hyperlink{protocolthe-p}{the} human-\/readable ASCII representation of \hyperlink{protocolthe-p}{the} address. 
\end{DoxyReturn}


The documentation for this class was generated from the following files:\begin{DoxyCompactItemize}
\item 
/home/greearb/git/xorp.ct.github/xorp/libxorp/mac.hh\item 
/home/greearb/git/xorp.ct.github/xorp/libxorp/mac.cc\end{DoxyCompactItemize}
