\hypertarget{classVertex}{
\section{Vertex Class Reference}
\label{classVertex}\index{Vertex@{Vertex}}
}


A vertex in \hyperlink{protocolthe-p}{the} shortest path tree.  




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

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

\begin{DoxyCompactList}\small\item\em Default constructor for \hyperlink{classVertex}{Vertex}. \item\end{DoxyCompactList}\item 
\hyperlink{classVertex_a58f5eff7134ab6bd7caf76c4424225e7}{Vertex} (const \hyperlink{classNeighbor}{Neighbor} \&n)
\begin{DoxyCompactList}\small\item\em Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a \hyperlink{classNeighbor}{Neighbor}. \item\end{DoxyCompactList}\item 
\hyperlink{classVertex_a1a53bec0333000c6dae2b5e8b80231c2}{Vertex} (const \hyperlink{classTwoHopNeighbor}{TwoHopNeighbor} \&n2)
\begin{DoxyCompactList}\small\item\em Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a \hyperlink{classTwoHopNeighbor}{TwoHopNeighbor}. \item\end{DoxyCompactList}\item 
\hyperlink{classVertex_acea759078e8c8abcde599cc6c63f701c}{Vertex} (const \hyperlink{classIPv4}{IPv4} \&main\_\-addr)
\begin{DoxyCompactList}\small\item\em Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a protocol address. \item\end{DoxyCompactList}\item 
\hyperlink{classVertex_adb44ca7645febefa39ce3502d60a79ca}{Vertex} (const \hyperlink{classTopologyEntry}{TopologyEntry} \&tc)
\begin{DoxyCompactList}\small\item\em Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a topology control tuple. \item\end{DoxyCompactList}\item 
bool \hyperlink{classVertex_ac0579dc4985f8cb6daac93af33b659a7}{operator$<$} (const \hyperlink{classVertex}{Vertex} \&other) const 
\begin{DoxyCompactList}\small\item\em Compare two \hyperlink{classVertex}{Vertex} instances for less-\/than ordering. \item\end{DoxyCompactList}\item 
bool \hyperlink{classVertex_a5245fa452f5cd5bee77753a7eb8728c9}{operator==} (const \hyperlink{classVertex}{Vertex} \&other) const 
\begin{DoxyCompactList}\small\item\em Compare two \hyperlink{classVertex}{Vertex} instances for equality. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a347679069531a00078b81ccdf21fefef}{
void {\bfseries set\_\-main\_\-addr} (const \hyperlink{classIPv4}{IPv4} \&main\_\-addr)}
\label{classVertex_a347679069531a00078b81ccdf21fefef}

\item 
\hypertarget{classVertex_ac3bd4d2ac5718090256a082295176f04}{
\hyperlink{classIPv4}{IPv4} {\bfseries main\_\-addr} () const }
\label{classVertex_ac3bd4d2ac5718090256a082295176f04}

\item 
\hypertarget{classVertex_a4a12ae2ec41d14cc6954f46a4c02d0a2}{
void {\bfseries set\_\-nodeid} (uint32\_\-t nid)}
\label{classVertex_a4a12ae2ec41d14cc6954f46a4c02d0a2}

\item 
\hypertarget{classVertex_a05cbe30c2b813e41ed650ba9d991cb8d}{
uint32\_\-t {\bfseries nodeid} () const }
\label{classVertex_a05cbe30c2b813e41ed650ba9d991cb8d}

\item 
\hypertarget{classVertex_a9f2152ccb99f71fd78963b94bb3236ce}{
void {\bfseries set\_\-is\_\-origin} (bool v)}
\label{classVertex_a9f2152ccb99f71fd78963b94bb3236ce}

\item 
bool \hyperlink{classVertex_a17cb81df4bdd9e1dbc6be5fd4057875a}{is\_\-origin} () const 
\item 
\hypertarget{classVertex_ac083b788efec714d10486103b0b4c91d}{
void {\bfseries set\_\-producer} (const \hyperlink{classIPv4}{IPv4} \&producer)}
\label{classVertex_ac083b788efec714d10486103b0b4c91d}

\item 
\hypertarget{classVertex_a441231e8a6dd9594eaae8c529690da3d}{
\hyperlink{classIPv4}{IPv4} {\bfseries producer} () const }
\label{classVertex_a441231e8a6dd9594eaae8c529690da3d}

\item 
\hypertarget{classVertex_af10b9f875ffe9af6ce63e91cf0ec27d5}{
void {\bfseries set\_\-faceid} (const \hyperlink{structOlsrTypes_a0be5017ad053311658089d9a795c63ac}{OlsrTypes::FaceID} fid)}
\label{classVertex_af10b9f875ffe9af6ce63e91cf0ec27d5}

\item 
\hypertarget{classVertex_a6f84b4c52c7dbcae7d8e54a146c3c66d}{
\hyperlink{structOlsrTypes_a0be5017ad053311658089d9a795c63ac}{OlsrTypes::FaceID} {\bfseries faceid} () const }
\label{classVertex_a6f84b4c52c7dbcae7d8e54a146c3c66d}

\item 
const \hyperlink{classLogicalLink}{LogicalLink} $\ast$ \hyperlink{classVertex_acff79c931c1681009e103d503fea69b4}{link} () const 
\item 
\hypertarget{classVertex_aa39f2dfd9027c0eef30984cd984963e0}{
void {\bfseries set\_\-link} (const \hyperlink{classLogicalLink}{LogicalLink} $\ast$l)}
\label{classVertex_aa39f2dfd9027c0eef30984cd984963e0}

\item 
const \hyperlink{classTwoHopLink}{TwoHopLink} $\ast$ \hyperlink{classVertex_a498efd53faf58474b969fb228cbef551}{twohop\_\-link} () const 
\item 
\hypertarget{classVertex_a3839cdd02e4e7c7cd9f07f7b7529fe20}{
void {\bfseries set\_\-twohop\_\-link} (const \hyperlink{classTwoHopLink}{TwoHopLink} $\ast$l2)}
\label{classVertex_a3839cdd02e4e7c7cd9f07f7b7529fe20}

\item 
\hypertarget{classVertex_a141cbda36b52baf9e5e71b685e45a032}{
void {\bfseries set\_\-type} (const \hyperlink{structOlsrTypes_a73921e658109f18cf96bfa1431400de3}{OlsrTypes::VertexType} t)}
\label{classVertex_a141cbda36b52baf9e5e71b685e45a032}

\item 
\hypertarget{classVertex_a72d52a87ad0be48fb4f7c11914e3b5e4}{
\hyperlink{structOlsrTypes_a73921e658109f18cf96bfa1431400de3}{OlsrTypes::VertexType} {\bfseries type} () const }
\label{classVertex_a72d52a87ad0be48fb4f7c11914e3b5e4}

\item 
\hypertarget{classVertex_aa7172f8fb7aff0a5ff5876671ca0c9ff}{
string {\bfseries str} () const }
\label{classVertex_aa7172f8fb7aff0a5ff5876671ca0c9ff}

\item 
\hypertarget{classVertex_ac0579dc4985f8cb6daac93af33b659a7}{
bool {\bfseries operator$<$} (const \hyperlink{classVertex}{Vertex} \&other) const }
\label{classVertex_ac0579dc4985f8cb6daac93af33b659a7}

\item 
\hypertarget{classVertex_a5245fa452f5cd5bee77753a7eb8728c9}{
bool {\bfseries operator==} (const \hyperlink{classVertex}{Vertex} \&other) const }
\label{classVertex_a5245fa452f5cd5bee77753a7eb8728c9}

\item 
\hypertarget{classVertex_a78902b6031cf6a4b68bd858132c41b2c}{
void {\bfseries set\_\-version} (\hyperlink{structOspfTypes_a60eb031df0c10af753789ae76b185ec2}{OspfTypes::Version} v)}
\label{classVertex_a78902b6031cf6a4b68bd858132c41b2c}

\item 
\hypertarget{classVertex_a04f946b160a1ece0375ddcbe165f35ec}{
\hyperlink{structOspfTypes_a60eb031df0c10af753789ae76b185ec2}{OspfTypes::Version} {\bfseries get\_\-version} () const }
\label{classVertex_a04f946b160a1ece0375ddcbe165f35ec}

\item 
\hypertarget{classVertex_a4c35a63e720581bf6bebf232f4e70857}{
void {\bfseries set\_\-type} (\hyperlink{structOspfTypes_a286fe55f20721d44a78924810daf2c59}{OspfTypes::VertexType} t)}
\label{classVertex_a4c35a63e720581bf6bebf232f4e70857}

\item 
\hypertarget{classVertex_a70b85afb052ba2557e3354bb4facc4cf}{
\hyperlink{structOspfTypes_a286fe55f20721d44a78924810daf2c59}{OspfTypes::VertexType} {\bfseries get\_\-type} () const }
\label{classVertex_a70b85afb052ba2557e3354bb4facc4cf}

\item 
\hypertarget{classVertex_a52c0ec086424f69c7131f4309f18d56d}{
void {\bfseries set\_\-nodeid} (uint32\_\-t nodeid)}
\label{classVertex_a52c0ec086424f69c7131f4309f18d56d}

\item 
\hypertarget{classVertex_aa554454e4f7bd4adfee5c2289621d34c}{
uint32\_\-t {\bfseries get\_\-nodeid} () const }
\label{classVertex_aa554454e4f7bd4adfee5c2289621d34c}

\item 
void \hyperlink{classVertex_a45e5e62ad518142f8b2a65f841425d2d}{set\_\-lsa} (\hyperlink{classref__ptr}{Lsa::LsaRef} lsar)
\begin{DoxyCompactList}\small\item\em OSPFv2 only. \item\end{DoxyCompactList}\item 
\hyperlink{classref__ptr}{Lsa::LsaRef} \hyperlink{classVertex_a9c189c369d0f274ff30b2a2d8e5551c6}{get\_\-lsa} () const 
\begin{DoxyCompactList}\small\item\em OSPFv2 only. \item\end{DoxyCompactList}\item 
list$<$ \hyperlink{classref__ptr}{Lsa::LsaRef} $>$ \& \hyperlink{classVertex_a780da1032193ba3a621b583f7069602e}{get\_\-lsas} ()
\begin{DoxyCompactList}\small\item\em OSPFv3 only. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a46d9b2a39b2ba8b844d21f8dc5343735}{
void {\bfseries set\_\-interface\_\-id} (uint32\_\-t interface\_\-id)}
\label{classVertex_a46d9b2a39b2ba8b844d21f8dc5343735}

\item 
\hypertarget{classVertex_a81ff5e1d1bc67ccd8fb97333df5e2c4c}{
uint32\_\-t {\bfseries get\_\-interface\_\-id} () const }
\label{classVertex_a81ff5e1d1bc67ccd8fb97333df5e2c4c}

\item 
\hypertarget{classVertex_a579e5ec25e63ae80106b3f874617c8fb}{
void {\bfseries set\_\-origin} (bool origin)}
\label{classVertex_a579e5ec25e63ae80106b3f874617c8fb}

\item 
\hypertarget{classVertex_ae0253c2f8d85d4988bfa83819e23e1a5}{
bool {\bfseries get\_\-origin} () const }
\label{classVertex_ae0253c2f8d85d4988bfa83819e23e1a5}

\item 
\hypertarget{classVertex_a82ba6f0f3ac0d63bcb84138c6b45fa28}{
void {\bfseries set\_\-address} (\hyperlink{classIPv4}{IPv4} address)}
\label{classVertex_a82ba6f0f3ac0d63bcb84138c6b45fa28}

\item 
\hypertarget{classVertex_af955e837f2bf5318715024a39611869c}{
\hyperlink{classIPv4}{IPv4} {\bfseries get\_\-address\_\-ipv4} () const }
\label{classVertex_af955e837f2bf5318715024a39611869c}

\item 
\hypertarget{classVertex_ac6d4dd84b9b27c36ecd460940f307edd}{
void {\bfseries set\_\-address} (\hyperlink{classIPv6}{IPv6} address)}
\label{classVertex_ac6d4dd84b9b27c36ecd460940f307edd}

\item 
\hypertarget{classVertex_a085b4179d8f743aedb942a5b03dcec0e}{
\hyperlink{classIPv6}{IPv6} {\bfseries get\_\-address\_\-ipv6} () const }
\label{classVertex_a085b4179d8f743aedb942a5b03dcec0e}

\item 
\hypertarget{classVertex_a5a7e36989e71ed1402f15796041716ca}{
void {\bfseries set\_\-nexthop\_\-id} (uint32\_\-t nexthop\_\-id)}
\label{classVertex_a5a7e36989e71ed1402f15796041716ca}

\item 
\hypertarget{classVertex_aa5e48f2ba7de1d2214e665523c68fc43}{
uint32\_\-t {\bfseries get\_\-nexthop\_\-id} () const }
\label{classVertex_aa5e48f2ba7de1d2214e665523c68fc43}

\item 
\hypertarget{classVertex_aa7172f8fb7aff0a5ff5876671ca0c9ff}{
string {\bfseries str} () const }
\label{classVertex_aa7172f8fb7aff0a5ff5876671ca0c9ff}

\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classVertex_affd47fc452281772cff21fba91730155}{
bool \hyperlink{classVertex_affd47fc452281772cff21fba91730155}{\_\-is\_\-origin}}
\label{classVertex_affd47fc452281772cff21fba91730155}

\begin{DoxyCompactList}\small\item\em true if this \hyperlink{classVertex}{Vertex} represents this OLSR router. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a5d20dd74464ab92754efb6a40d5d1042}{
\hyperlink{structOlsrTypes_a73921e658109f18cf96bfa1431400de3}{OlsrTypes::VertexType} \hyperlink{classVertex_a5d20dd74464ab92754efb6a40d5d1042}{\_\-t}}
\label{classVertex_a5d20dd74464ab92754efb6a40d5d1042}

\begin{DoxyCompactList}\small\item\em The type of node in \hyperlink{protocolthe-p}{the} OLSR link state databases from which this \hyperlink{classVertex}{Vertex} is derived. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a2525822f00f5c2a899d52b9620e33bd6}{
uint32\_\-t \hyperlink{classVertex_a2525822f00f5c2a899d52b9620e33bd6}{\_\-nodeid}}
\label{classVertex_a2525822f00f5c2a899d52b9620e33bd6}

\begin{DoxyCompactList}\small\item\em ID of \hyperlink{protocolthe-p}{the} \hyperlink{classNeighbor}{Neighbor}, \hyperlink{classTwoHopNeighbor}{TwoHopNeighbor} or \hyperlink{classTopologyEntry}{TopologyEntry} responsible for \hyperlink{protocolthe-p}{the} creation of this vertex. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a5d95514d3c862a938e2a2a5f63d5141e}{
\hyperlink{classIPv4}{IPv4} \hyperlink{classVertex_a5d95514d3c862a938e2a2a5f63d5141e}{\_\-main\_\-addr}}
\label{classVertex_a5d95514d3c862a938e2a2a5f63d5141e}

\begin{DoxyCompactList}\small\item\em The main protocol address of \hyperlink{protocolthe-p}{the} OLSR node is used as \hyperlink{protocolthe-p}{the} unique node identifier in \hyperlink{protocolthe-p}{the} shortest-\/path tree. \item\end{DoxyCompactList}\item 
\hyperlink{classIPv4}{IPv4} \hyperlink{classVertex_a998e65b46713a86497a6ff17aca0d18c}{\_\-producer}
\begin{DoxyCompactList}\small\item\em The main protocol address of \hyperlink{protocolthe-p}{the} OLSR node from where this vertex was learned. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a086ceeddebc3e5d83afaf1697554e817}{
\hyperlink{structOlsrTypes_a0be5017ad053311658089d9a795c63ac}{OlsrTypes::FaceID} \hyperlink{classVertex_a086ceeddebc3e5d83afaf1697554e817}{\_\-faceid}}
\label{classVertex_a086ceeddebc3e5d83afaf1697554e817}

\begin{DoxyCompactList}\small\item\em If \hyperlink{protocolthe-p}{the} OLSR node which this vertex represents is directly connected to \hyperlink{protocolthe-p}{the} origin, this is \hyperlink{protocolthe-p}{the} FaceID which should be used to reach \hyperlink{protocolthe-p}{the} next hop. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a55eae6b850c446dcc54584fb81692f3f}{
const \hyperlink{classLogicalLink}{LogicalLink} $\ast$ \hyperlink{classVertex_a55eae6b850c446dcc54584fb81692f3f}{\_\-link}}
\label{classVertex_a55eae6b850c446dcc54584fb81692f3f}

\begin{DoxyCompactList}\small\item\em If this is a one-\/hop neighbor vertex, this is \hyperlink{protocolthe-p}{the} link which was chosen to reach \hyperlink{protocolthe-p}{the} neighbor. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a9b73f9fdd8369a60a326fbb9ba30d624}{
const \hyperlink{classTwoHopLink}{TwoHopLink} $\ast$ \hyperlink{classVertex_a9b73f9fdd8369a60a326fbb9ba30d624}{\_\-twohop\_\-link}}
\label{classVertex_a9b73f9fdd8369a60a326fbb9ba30d624}

\begin{DoxyCompactList}\small\item\em If this is a two-\/hop neighbor vertex, this is \hyperlink{protocolthe-p}{the} link which was chosen to reach it. \item\end{DoxyCompactList}\item 
\hypertarget{classVertex_a5575f345abbaa81fa510b06017cbc61d}{
\hyperlink{structOspfTypes_a60eb031df0c10af753789ae76b185ec2}{OspfTypes::Version} {\bfseries \_\-version}}
\label{classVertex_a5575f345abbaa81fa510b06017cbc61d}

\item 
\hypertarget{classVertex_a0966b861e024a14bbc935f255298488d}{
\hyperlink{structOspfTypes_a286fe55f20721d44a78924810daf2c59}{OspfTypes::VertexType} {\bfseries \_\-t}}
\label{classVertex_a0966b861e024a14bbc935f255298488d}

\item 
\hypertarget{classVertex_aff6be4bae6ac658c65eec4a708ee4f9a}{
uint32\_\-t {\bfseries \_\-interface\_\-id}}
\label{classVertex_aff6be4bae6ac658c65eec4a708ee4f9a}

\item 
\hypertarget{classVertex_ae9734681d40fd6479d30e75985e65ca8}{
bool {\bfseries \_\-origin}}
\label{classVertex_ae9734681d40fd6479d30e75985e65ca8}

\item 
\hypertarget{classVertex_a40df9b14512d92746f8413cc38eed75b}{
\hyperlink{classIPv4}{IPv4} {\bfseries \_\-address\_\-ipv4}}
\label{classVertex_a40df9b14512d92746f8413cc38eed75b}

\item 
\hypertarget{classVertex_ab3f8113e0e940c8a966450b4a7305422}{
\hyperlink{classIPv6}{IPv6} {\bfseries \_\-address\_\-ipv6}}
\label{classVertex_ab3f8113e0e940c8a966450b4a7305422}

\item 
\hypertarget{classVertex_a747ae5c0bd882eae8bd8abdb666c68a2}{
uint32\_\-t {\bfseries \_\-nexthop\_\-id}}
\label{classVertex_a747ae5c0bd882eae8bd8abdb666c68a2}

\item 
\hypertarget{classVertex_aaa60fbeb17a8d4571ffba60a5ff01c8c}{
list$<$ \hyperlink{classref__ptr}{Lsa::LsaRef} $>$ {\bfseries \_\-lsars}}
\label{classVertex_aaa60fbeb17a8d4571ffba60a5ff01c8c}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
A vertex in \hyperlink{protocolthe-p}{the} shortest path tree. \hyperlink{classVertex}{Vertex} required for computing \hyperlink{protocolthe-p}{the} shortest path tree. 

\subsection{Constructor \& Destructor Documentation}
\hypertarget{classVertex_a58f5eff7134ab6bd7caf76c4424225e7}{
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\subsubsection[{Vertex}]{\setlength{\rightskip}{0pt plus 5cm}Vertex::Vertex (
\begin{DoxyParamCaption}
\item[{const {\bf Neighbor} \&}]{n}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline, explicit\mbox{]}}}}
\label{classVertex_a58f5eff7134ab6bd7caf76c4424225e7}


Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a \hyperlink{classNeighbor}{Neighbor}. 

A neighbor vertex is learned from \hyperlink{protocolthe-p}{the} neighbor itself, so mark it as \hyperlink{protocolthe-p}{the} producer.


\begin{DoxyParams}{Parameters}
{\em n} & \hyperlink{protocolthe-p}{the} \hyperlink{classNeighbor}{Neighbor} represented by this \hyperlink{classVertex}{Vertex}. \\
\hline
\end{DoxyParams}
\hypertarget{classVertex_a1a53bec0333000c6dae2b5e8b80231c2}{
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\subsubsection[{Vertex}]{\setlength{\rightskip}{0pt plus 5cm}Vertex::Vertex (
\begin{DoxyParamCaption}
\item[{const {\bf TwoHopNeighbor} \&}]{n2}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline, explicit\mbox{]}}}}
\label{classVertex_a1a53bec0333000c6dae2b5e8b80231c2}


Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a \hyperlink{classTwoHopNeighbor}{TwoHopNeighbor}. 

The producer of a two-\/hop vertex is \hyperlink{protocolthe-p}{the} one-\/hop neighbor which advertised \hyperlink{protocolthe-p}{the} link we choose to reach it, which we set after creation using set\_\-producer().

The face ID is not known until \hyperlink{protocolthe-p}{the} SPT calculation has run and paths have been chosen; it will be that of \hyperlink{protocolthe-p}{the} path selected at radius = 1.


\begin{DoxyParams}{Parameters}
{\em n2} & \hyperlink{protocolthe-p}{the} \hyperlink{classTwoHopNeighbor}{TwoHopNeighbor} represented by this \hyperlink{classVertex}{Vertex}. \\
\hline
\end{DoxyParams}
\hypertarget{classVertex_acea759078e8c8abcde599cc6c63f701c}{
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\subsubsection[{Vertex}]{\setlength{\rightskip}{0pt plus 5cm}Vertex::Vertex (
\begin{DoxyParamCaption}
\item[{const {\bf IPv4} \&}]{main\_\-addr}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline, explicit\mbox{]}}}}
\label{classVertex_acea759078e8c8abcde599cc6c63f701c}


Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a protocol address. 

Typically used for sanity checking when populating \hyperlink{protocolthe-p}{the} SPT from OLSR's TC database. \hypertarget{classVertex_adb44ca7645febefa39ce3502d60a79ca}{
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\index{Vertex@{Vertex}!Vertex@{Vertex}}
\subsubsection[{Vertex}]{\setlength{\rightskip}{0pt plus 5cm}Vertex::Vertex (
\begin{DoxyParamCaption}
\item[{const {\bf TopologyEntry} \&}]{tc}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline, explicit\mbox{]}}}}
\label{classVertex_adb44ca7645febefa39ce3502d60a79ca}


Explicit constructor to: Create a \hyperlink{classVertex}{Vertex} from a topology control tuple. 

The producer of a TC vertex is \hyperlink{protocolthe-p}{the} OLSR node which advertised \hyperlink{protocolthe-p}{the} TC entry from which \hyperlink{protocolthe-p}{the} vertex has been created. 

\subsection{Member Function Documentation}
\hypertarget{classVertex_a9c189c369d0f274ff30b2a2d8e5551c6}{
\index{Vertex@{Vertex}!get\_\-lsa@{get\_\-lsa}}
\index{get\_\-lsa@{get\_\-lsa}!Vertex@{Vertex}}
\subsubsection[{get\_\-lsa}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Lsa::LsaRef} Vertex::get\_\-lsa (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_a9c189c369d0f274ff30b2a2d8e5551c6}


OSPFv2 only. 

Get \hyperlink{protocolthe-p}{the} LSA that is responsible for this vertex. \hypertarget{classVertex_a780da1032193ba3a621b583f7069602e}{
\index{Vertex@{Vertex}!get\_\-lsas@{get\_\-lsas}}
\index{get\_\-lsas@{get\_\-lsas}!Vertex@{Vertex}}
\subsubsection[{get\_\-lsas}]{\setlength{\rightskip}{0pt plus 5cm}list$<${\bf Lsa::LsaRef}$>$\& Vertex::get\_\-lsas (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_a780da1032193ba3a621b583f7069602e}


OSPFv3 only. 

Return \hyperlink{protocolthe-p}{the} list of LSAs that may be responsible for this vertex. \hypertarget{classVertex_a17cb81df4bdd9e1dbc6be5fd4057875a}{
\index{Vertex@{Vertex}!is\_\-origin@{is\_\-origin}}
\index{is\_\-origin@{is\_\-origin}!Vertex@{Vertex}}
\subsubsection[{is\_\-origin}]{\setlength{\rightskip}{0pt plus 5cm}bool Vertex::is\_\-origin (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_a17cb81df4bdd9e1dbc6be5fd4057875a}
\begin{DoxyReturn}{Returns}
true if this node represents this router. 
\end{DoxyReturn}
\hypertarget{classVertex_acff79c931c1681009e103d503fea69b4}{
\index{Vertex@{Vertex}!link@{link}}
\index{link@{link}!Vertex@{Vertex}}
\subsubsection[{link}]{\setlength{\rightskip}{0pt plus 5cm}const {\bf LogicalLink}$\ast$ Vertex::link (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_acff79c931c1681009e103d503fea69b4}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} \hyperlink{classLogicalLink}{LogicalLink} associated with a one-\/hop neighbor. 
\end{DoxyReturn}
\hypertarget{classVertex_ac0579dc4985f8cb6daac93af33b659a7}{
\index{Vertex@{Vertex}!operator$<$@{operator$<$}}
\index{operator$<$@{operator$<$}!Vertex@{Vertex}}
\subsubsection[{operator$<$}]{\setlength{\rightskip}{0pt plus 5cm}bool Vertex::operator$<$ (
\begin{DoxyParamCaption}
\item[{const {\bf Vertex} \&}]{other}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_ac0579dc4985f8cb6daac93af33b659a7}


Compare two \hyperlink{classVertex}{Vertex} instances for less-\/than ordering. 

Collation order for sort: 1. Main address; always unique.

XXX The following two can't be relied upon... because differentiating them at all means we can't look up nodes purely by their address! 2. Is origin vertex: true, false. 3. \hyperlink{classVertex}{Vertex} type: origin, onehop, twohop, tc.


\begin{DoxyParams}{Parameters}
{\em other} & node to compare with. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
true if this node comes before \hyperlink{protocolthe-p}{the} other node. 
\end{DoxyReturn}
\hypertarget{classVertex_a5245fa452f5cd5bee77753a7eb8728c9}{
\index{Vertex@{Vertex}!operator==@{operator==}}
\index{operator==@{operator==}!Vertex@{Vertex}}
\subsubsection[{operator==}]{\setlength{\rightskip}{0pt plus 5cm}bool Vertex::operator== (
\begin{DoxyParamCaption}
\item[{const {\bf Vertex} \&}]{other}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_a5245fa452f5cd5bee77753a7eb8728c9}


Compare two \hyperlink{classVertex}{Vertex} instances for equality. 

Comparison is performed solely on \hyperlink{protocolthe-p}{the} main address of \hyperlink{protocolthe-p}{the} node, which is always unique.


\begin{DoxyParams}{Parameters}
{\em other} & node to compare with. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
true if this node and \hyperlink{protocolthe-p}{the} other node are equal. 
\end{DoxyReturn}
\hypertarget{classVertex_a45e5e62ad518142f8b2a65f841425d2d}{
\index{Vertex@{Vertex}!set\_\-lsa@{set\_\-lsa}}
\index{set\_\-lsa@{set\_\-lsa}!Vertex@{Vertex}}
\subsubsection[{set\_\-lsa}]{\setlength{\rightskip}{0pt plus 5cm}void Vertex::set\_\-lsa (
\begin{DoxyParamCaption}
\item[{{\bf Lsa::LsaRef}}]{lsar}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_a45e5e62ad518142f8b2a65f841425d2d}


OSPFv2 only. 

Set \hyperlink{protocolthe-p}{the} LSA that is responsible for this vertex. \hypertarget{classVertex_a498efd53faf58474b969fb228cbef551}{
\index{Vertex@{Vertex}!twohop\_\-link@{twohop\_\-link}}
\index{twohop\_\-link@{twohop\_\-link}!Vertex@{Vertex}}
\subsubsection[{twohop\_\-link}]{\setlength{\rightskip}{0pt plus 5cm}const {\bf TwoHopLink}$\ast$ Vertex::twohop\_\-link (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classVertex_a498efd53faf58474b969fb228cbef551}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} \hyperlink{classTwoHopLink}{TwoHopLink} associated with a two-\/hop neighbor. 
\end{DoxyReturn}


\subsection{Member Data Documentation}
\hypertarget{classVertex_a998e65b46713a86497a6ff17aca0d18c}{
\index{Vertex@{Vertex}!\_\-producer@{\_\-producer}}
\index{\_\-producer@{\_\-producer}!Vertex@{Vertex}}
\subsubsection[{\_\-producer}]{\setlength{\rightskip}{0pt plus 5cm}{\bf IPv4} {\bf Vertex::\_\-producer}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{classVertex_a998e65b46713a86497a6ff17aca0d18c}


The main protocol address of \hyperlink{protocolthe-p}{the} OLSR node from where this vertex was learned. 

In \hyperlink{protocolthe-p}{the} routing CLI this is referred to as \hyperlink{protocolthe-p}{the} origin; it is NOT \hyperlink{protocolthe-p}{the} origin of \hyperlink{protocolthe-p}{the} SPT graph. 

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