\hypertarget{classRefTrieNode}{
\section{RefTrieNode$<$ A, Payload $>$ Class Template Reference}
\label{classRefTrieNode}\index{RefTrieNode@{RefTrieNode}}
}


\hyperlink{classRefTrieNode}{RefTrieNode} definition.  




{\ttfamily \#include $<$ref\_\-trie.hh$>$}

\subsection*{Public Types}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classRefTrieNode_ab524d9e85775f232e9a2dfb8d57a7dce}{
typedef \hyperlink{classIPNet}{IPNet}$<$ A $>$ {\bfseries Key}}
\label{classRefTrieNode_ab524d9e85775f232e9a2dfb8d57a7dce}

\item 
\hypertarget{classRefTrieNode_a59f56f144a3f04e82d74b787f3252caf}{
typedef \hyperlink{classMiniTraits}{MiniTraits}$<$ Payload $>$::NonConst {\bfseries PPayload}}
\label{classRefTrieNode_a59f56f144a3f04e82d74b787f3252caf}

\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classRefTrieNode_abe0c2522c562cb6a13574b8a2c59a27b}{
\hyperlink{classRefTrieNode_abe0c2522c562cb6a13574b8a2c59a27b}{RefTrieNode} ()}
\label{classRefTrieNode_abe0c2522c562cb6a13574b8a2c59a27b}

\begin{DoxyCompactList}\small\item\em Constructors. \item\end{DoxyCompactList}\item 
\hypertarget{classRefTrieNode_afee1a0245f39860918947fee219e8128}{
{\bfseries RefTrieNode} (const \hyperlink{classIPNet}{Key} \&key, const Payload \&p, \hyperlink{classRefTrieNode}{RefTrieNode} $\ast$up=0)}
\label{classRefTrieNode_afee1a0245f39860918947fee219e8128}

\item 
\hypertarget{classRefTrieNode_a760001320c27cadda342f6186073130a}{
{\bfseries RefTrieNode} (const \hyperlink{classIPNet}{Key} \&key, \hyperlink{classRefTrieNode}{RefTrieNode} $\ast$up=0)}
\label{classRefTrieNode_a760001320c27cadda342f6186073130a}

\item 
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ \hyperlink{classRefTrieNode_af62c0a2e20cf8b483af8f98d80fee221}{erase} ()
\begin{DoxyCompactList}\small\item\em erase current node, replumb. \item\end{DoxyCompactList}\item 
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ \hyperlink{classRefTrieNode_a6b217626620d86f279ac6b6e48573cd3}{find} (const \hyperlink{classIPNet}{Key} \&key)
\begin{DoxyCompactList}\small\item\em main search routine. \item\end{DoxyCompactList}\item 
\hypertarget{classRefTrieNode_aded5b2afa8031835e5c46e473402e114}{
const \hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries const\_\-find} (const \hyperlink{classIPNet}{Key} \&key) const }
\label{classRefTrieNode_aded5b2afa8031835e5c46e473402e114}

\item 
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ \hyperlink{classRefTrieNode_a13d13e51ddcceda8029f3d552927b3f8}{find\_\-subtree} (const \hyperlink{classIPNet}{Key} \&key)
\begin{DoxyCompactList}\small\item\em aux search routine. \item\end{DoxyCompactList}\item 
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ \hyperlink{classRefTrieNode_a5e97c092b8f3153515aacc181976a08d}{lower\_\-bound} (const \hyperlink{classIPNet}{Key} \&key)
\begin{DoxyCompactList}\small\item\em Given a key, find \hyperlink{protocolthe-p}{the} node with that key and a payload. \item\end{DoxyCompactList}\item 
\hypertarget{classRefTrieNode_ac7f9c9c5b4bf6be280ebd4be6d06eca3}{
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries get\_\-left} ()}
\label{classRefTrieNode_ac7f9c9c5b4bf6be280ebd4be6d06eca3}

\item 
\hypertarget{classRefTrieNode_a3604fe91aa9986c1fbc4cb4895185e94}{
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries get\_\-right} ()}
\label{classRefTrieNode_a3604fe91aa9986c1fbc4cb4895185e94}

\item 
\hypertarget{classRefTrieNode_aaf3fc7ddf0338c8f5261f877059b3df9}{
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries get\_\-parent} ()}
\label{classRefTrieNode_aaf3fc7ddf0338c8f5261f877059b3df9}

\item 
\hypertarget{classRefTrieNode_a8d8d0e3c5eb2fb5d0dc8e3b052e70731}{
bool {\bfseries has\_\-payload} () const }
\label{classRefTrieNode_a8d8d0e3c5eb2fb5d0dc8e3b052e70731}

\item 
\hypertarget{classRefTrieNode_ad1e26503fb01231ceb571e8f7bb7570c}{
bool {\bfseries has\_\-active\_\-payload} () const }
\label{classRefTrieNode_ad1e26503fb01231ceb571e8f7bb7570c}

\item 
\hypertarget{classRefTrieNode_ab6e77bf77344b0775f5728e6297ac583}{
const Payload \& {\bfseries const\_\-p} () const }
\label{classRefTrieNode_ab6e77bf77344b0775f5728e6297ac583}

\item 
\hypertarget{classRefTrieNode_a12005342f15920b863db8dcb28a346fc}{
Payload \& {\bfseries p} ()}
\label{classRefTrieNode_a12005342f15920b863db8dcb28a346fc}

\item 
\hypertarget{classRefTrieNode_aa99a64108e6b6a396914d26a5a544125}{
void {\bfseries set\_\-payload} (const Payload \&p)}
\label{classRefTrieNode_aa99a64108e6b6a396914d26a5a544125}

\item 
\hypertarget{classRefTrieNode_a363b3872b708f372a1fe43d77b1e30c7}{
uint32\_\-t {\bfseries references} () const }
\label{classRefTrieNode_a363b3872b708f372a1fe43d77b1e30c7}

\item 
\hypertarget{classRefTrieNode_a75cde5398d844744da022b9a501d9591}{
void {\bfseries incr\_\-refcount} ()}
\label{classRefTrieNode_a75cde5398d844744da022b9a501d9591}

\item 
\hypertarget{classRefTrieNode_a3e9caad202e8a57bcb7ac71e29a72cb2}{
void {\bfseries decr\_\-refcount} ()}
\label{classRefTrieNode_a3e9caad202e8a57bcb7ac71e29a72cb2}

\item 
\hypertarget{classRefTrieNode_adb333cf1625c214c8555d909357b020c}{
bool {\bfseries deleted} () const }
\label{classRefTrieNode_adb333cf1625c214c8555d909357b020c}

\item 
\hypertarget{classRefTrieNode_a91a2498e630b78bec651e54a00bfe831}{
const \hyperlink{classIPNet}{Key} \& {\bfseries k} () const }
\label{classRefTrieNode_a91a2498e630b78bec651e54a00bfe831}

\item 
\hypertarget{classRefTrieNode_a311afa955652743a4ca5fd3c5e66282d}{
void {\bfseries print} (int indent, const char $\ast$msg) const }
\label{classRefTrieNode_a311afa955652743a4ca5fd3c5e66282d}

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

\item 
\hypertarget{classRefTrieNode_ac1ae5acabf1cf46a800aebf254c30b31}{
void \hyperlink{classRefTrieNode_ac1ae5acabf1cf46a800aebf254c30b31}{delete\_\-subtree} ()}
\label{classRefTrieNode_ac1ae5acabf1cf46a800aebf254c30b31}

\begin{DoxyCompactList}\small\item\em helper function to delete an entire subtree (including \hyperlink{protocolthe-p}{the} root). \item\end{DoxyCompactList}\item 
\hypertarget{classRefTrieNode_ad3769c2a8889f25e7df44c5f6c70c3a6}{
void \hyperlink{classRefTrieNode_ad3769c2a8889f25e7df44c5f6c70c3a6}{validate} (const \hyperlink{classRefTrieNode}{RefTrieNode} $\ast$parent) const }
\label{classRefTrieNode_ad3769c2a8889f25e7df44c5f6c70c3a6}

\begin{DoxyCompactList}\small\item\em debugging, validates a node by checking pointers and Key invariants. \item\end{DoxyCompactList}\item 
bool \hyperlink{classRefTrieNode_a4bb6dcb2726b28a4c424945a6f981ae6}{is\_\-left} () const 
\item 
\hypertarget{classRefTrieNode_a436078fc41db9a5744ab9945b2ed9d10}{
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries leftmost} ()}
\label{classRefTrieNode_a436078fc41db9a5744ab9945b2ed9d10}

\item 
void \hyperlink{classRefTrieNode_aa73f98473386f7a6a5eb3fff7e2dbb30}{find\_\-bounds} (const A \&a, A \&lo, A \&hi) const 
\item 
A \hyperlink{classRefTrieNode_acf06961d9d45ba34432a6bd6d4ec11f2}{low} () const 
\item 
A \hyperlink{classRefTrieNode_afbf1805dfcb777908adbf29c4862e183}{high} () const 
\end{DoxyCompactItemize}
\subsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
static \hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ \hyperlink{classRefTrieNode_a1edf09811a1bb304d748935306495cd2}{insert} (\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$$\ast$root, const \hyperlink{classIPNet}{Key} \&key, const Payload \&p, bool \&replaced)
\begin{DoxyCompactList}\small\item\em add a node to a subtree \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classRefTrieNode_a6e918c1b2cb3504f43efd7d6a0c15ee6}{
void {\bfseries delete\_\-payload} (Payload $\ast$p)}
\label{classRefTrieNode_a6e918c1b2cb3504f43efd7d6a0c15ee6}

\item 
\hypertarget{classRefTrieNode_a29fc208fd755a9212e9e0fcfab4c60fd}{
void {\bfseries dump} (const char $\ast$msg) const }
\label{classRefTrieNode_a29fc208fd755a9212e9e0fcfab4c60fd}

\item 
\hypertarget{classRefTrieNode_a1189bed044c2a078af2d25229d76d7b6}{
{\footnotesize template$<$$>$ }\\void {\bfseries delete\_\-payload} (const \hyperlink{classChainedSubnetRoute}{ChainedSubnetRoute}$<$ \hyperlink{classIPv4}{IPv4} $>$ $\ast$p)}
\label{classRefTrieNode_a1189bed044c2a078af2d25229d76d7b6}

\item 
\hypertarget{classRefTrieNode_ad80350403c0d4c259cdffa26c228979e}{
{\footnotesize template$<$$>$ }\\void {\bfseries delete\_\-payload} (const \hyperlink{classChainedSubnetRoute}{ChainedSubnetRoute}$<$ \hyperlink{classIPv6}{IPv6} $>$ $\ast$p)}
\label{classRefTrieNode_ad80350403c0d4c259cdffa26c228979e}

\item 
\hypertarget{classRefTrieNode_adf7a05849cbcfd052ee7d893eb7072ab}{
{\footnotesize template$<$$>$ }\\void {\bfseries delete\_\-payload} (const \hyperlink{classSubnetRoute}{SubnetRoute}$<$ \hyperlink{classIPv4}{IPv4} $>$ $\ast$p)}
\label{classRefTrieNode_adf7a05849cbcfd052ee7d893eb7072ab}

\item 
\hypertarget{classRefTrieNode_a97df805ee4204710b30b2cd319e00597}{
{\footnotesize template$<$$>$ }\\void {\bfseries delete\_\-payload} (const \hyperlink{classSubnetRoute}{SubnetRoute}$<$ \hyperlink{classIPv6}{IPv6} $>$ $\ast$p)}
\label{classRefTrieNode_a97df805ee4204710b30b2cd319e00597}

\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classRefTrieNode_abc39a47fe3b77f1e8df9bf1ac033d529}{
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries \_\-up}}
\label{classRefTrieNode_abc39a47fe3b77f1e8df9bf1ac033d529}

\item 
\hypertarget{classRefTrieNode_aaeb9c57a4312738ae5618782af4ac66a}{
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries \_\-left}}
\label{classRefTrieNode_aaeb9c57a4312738ae5618782af4ac66a}

\item 
\hypertarget{classRefTrieNode_ab55ce3aea6d0320ae77d6c4868331cd1}{
\hyperlink{classRefTrieNode}{RefTrieNode} $\ast$ {\bfseries \_\-right}}
\label{classRefTrieNode_ab55ce3aea6d0320ae77d6c4868331cd1}

\item 
\hypertarget{classRefTrieNode_a76778eba27ca4bef2ee387411c51ddef}{
\hyperlink{classIPNet}{Key} {\bfseries \_\-k}}
\label{classRefTrieNode_a76778eba27ca4bef2ee387411c51ddef}

\item 
\hypertarget{classRefTrieNode_a130546bee2979f5a10ee727f999a18d9}{
PPayload $\ast$ {\bfseries \_\-p}}
\label{classRefTrieNode_a130546bee2979f5a10ee727f999a18d9}

\item 
\hypertarget{classRefTrieNode_a64b5c68fc7cc4f327a8c4176bda7b627}{
uint32\_\-t {\bfseries \_\-references}}
\label{classRefTrieNode_a64b5c68fc7cc4f327a8c4176bda7b627}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
\subsubsection*{template$<$class A, class Payload$>$ class RefTrieNode$<$ A, Payload $>$}

\hyperlink{classRefTrieNode}{RefTrieNode} definition. RefTrieNode's are \hyperlink{protocolthe-p}{the} elements of a \hyperlink{classRefTrie}{RefTrie}. Each node is associated to a Key and possibly a Payload. \hyperlink{classNodes}{Nodes} with a Payload (\char`\"{}full\char`\"{}) can have 0, 1 or 2 children. \hyperlink{classNodes}{Nodes} without a Payload (\char`\"{}empty\char`\"{}) can only be internal nodes, and MUST have 2 children (or they have no reason to exist).

Children have a Key which is strictly contained in their parent's Key -\/-\/ more precisely, they are in either \hyperlink{protocolthe-p}{the} left or \hyperlink{protocolthe-p}{the} right half of \hyperlink{protocolthe-p}{the} parent's Key. The branch to which a child is attached (left or right) is defined accordingly. 

\subsection{Member Function Documentation}
\hypertarget{classRefTrieNode_af62c0a2e20cf8b483af8f98d80fee221}{
\index{RefTrieNode@{RefTrieNode}!erase@{erase}}
\index{erase@{erase}!RefTrieNode@{RefTrieNode}}
\subsubsection[{erase}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ {\bf RefTrieNode}$<$ A, Payload $>$ $\ast$ {\bf RefTrieNode}$<$ A, Payload $>$::erase (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classRefTrieNode_af62c0a2e20cf8b483af8f98d80fee221}


erase current node, replumb. 

Remove this node, cleanup useless internal nodes.

Returns \hyperlink{protocolthe-p}{the} new root.

\begin{DoxyReturn}{Returns}
a pointer to \hyperlink{protocolthe-p}{the} root of \hyperlink{protocolthe-p}{the} trie. 
\end{DoxyReturn}
\hypertarget{classRefTrieNode_a6b217626620d86f279ac6b6e48573cd3}{
\index{RefTrieNode@{RefTrieNode}!find@{find}}
\index{find@{find}!RefTrieNode@{RefTrieNode}}
\subsubsection[{find}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ {\bf RefTrieNode}$<$ A, Payload $>$ $\ast$ {\bf RefTrieNode}$<$ A, Payload $>$::find (
\begin{DoxyParamCaption}
\item[{const {\bf Key} \&}]{key}
\end{DoxyParamCaption}
)}}
\label{classRefTrieNode_a6b217626620d86f279ac6b6e48573cd3}


main search routine. 

Finds \hyperlink{protocolthe-p}{the} most specific entry in \hyperlink{protocolthe-p}{the} subtree rooted at r that contains \hyperlink{protocolthe-p}{the} desired key and has a Payload.

Given a key, returns a node. \hypertarget{classRefTrieNode_aa73f98473386f7a6a5eb3fff7e2dbb30}{
\index{RefTrieNode@{RefTrieNode}!find\_\-bounds@{find\_\-bounds}}
\index{find\_\-bounds@{find\_\-bounds}!RefTrieNode@{RefTrieNode}}
\subsubsection[{find\_\-bounds}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ void {\bf RefTrieNode}$<$ A, Payload $>$::find\_\-bounds (
\begin{DoxyParamCaption}
\item[{const A \&}]{a, }
\item[{A \&}]{lo, }
\item[{A \&}]{hi}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classRefTrieNode_aa73f98473386f7a6a5eb3fff7e2dbb30}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} boundaries (\char`\"{}lo\char`\"{} and \char`\"{}hi\char`\"{}) of \hyperlink{protocolthe-p}{the} largest range that contains 'a' and maps to \hyperlink{protocolthe-p}{the} same route entry.
\end{DoxyReturn}
Algorithm: 
\begin{DoxyPre}
		n = find(a);
 		if we have no route (hence no default), provide a fake 0/0;
		set lo and hi to \hyperlink{protocolthe-p}{the} boundaries of \hyperlink{protocolthe-p}{the} current node.\end{DoxyPre}



\begin{DoxyPre} if n.is\_a\_leaf() we are done (results are \hyperlink{protocolthe-p}{the} extremes of \hyperlink{protocolthe-p}{the} entry)
 Otherwise: we are in an intermediate node, and a can be in positions
 1..5 if \hyperlink{protocolthe-p}{the} node has 2 children, or 1'..3' if it has 1 child.\end{DoxyPre}



\begin{DoxyPre}	n:		|---------------.----------------|
  a:                1    2        3      4     5
                       |--X--|         |--Y--|\end{DoxyPre}



\begin{DoxyPre}  a:                1'    2'        3'
                       |--X--|\end{DoxyPre}



\begin{DoxyPre} Behaviour is \hyperlink{protocolthe-p}{the} following:
  case 1 and 1':	lo already set, hi = (lowest address in X)-1
  case 2 and 2': set n = X and repeat
  case 3: lo = (highest addr in X)+1, hi = (lowest addr in Y)-1
  case 3': lo = (highest addr in X)+1, hi is already set
  case 4: set n = Y and repeat
  case 5:	lo = (highest addr in Y)+1, hi is already set
 \end{DoxyPre}
 \hypertarget{classRefTrieNode_a13d13e51ddcceda8029f3d552927b3f8}{
\index{RefTrieNode@{RefTrieNode}!find\_\-subtree@{find\_\-subtree}}
\index{find\_\-subtree@{find\_\-subtree}!RefTrieNode@{RefTrieNode}}
\subsubsection[{find\_\-subtree}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ {\bf RefTrieNode}$<$ A, Payload $>$ $\ast$ {\bf RefTrieNode}$<$ A, Payload $>$::find\_\-subtree (
\begin{DoxyParamCaption}
\item[{const {\bf Key} \&}]{key}
\end{DoxyParamCaption}
)}}
\label{classRefTrieNode_a13d13e51ddcceda8029f3d552927b3f8}


aux search routine. 

Finds \hyperlink{protocolthe-p}{the} subtree of key.

Given a key, returns a subtree contained in \hyperlink{protocolthe-p}{the} key, irrespective of \hyperlink{protocolthe-p}{the} presence of a payload in \hyperlink{protocolthe-p}{the} node. \hypertarget{classRefTrieNode_afbf1805dfcb777908adbf29c4862e183}{
\index{RefTrieNode@{RefTrieNode}!high@{high}}
\index{high@{high}!RefTrieNode@{RefTrieNode}}
\subsubsection[{high}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ A {\bf RefTrieNode}$<$ A, Payload $>$::high (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classRefTrieNode_afbf1805dfcb777908adbf29c4862e183}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} highest address in a subtree which has a route. Search starting from right or left until a full node is found. 
\end{DoxyReturn}
\hypertarget{classRefTrieNode_a1edf09811a1bb304d748935306495cd2}{
\index{RefTrieNode@{RefTrieNode}!insert@{insert}}
\index{insert@{insert}!RefTrieNode@{RefTrieNode}}
\subsubsection[{insert}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ {\bf RefTrieNode}$<$ A, Payload $>$ $\ast$ {\bf RefTrieNode}$<$ A, Payload $>$::insert (
\begin{DoxyParamCaption}
\item[{{\bf RefTrieNode}$<$ A, Payload $>$ $\ast$$\ast$}]{root, }
\item[{const {\bf Key} \&}]{x, }
\item[{const Payload \&}]{p, }
\item[{bool \&}]{replaced}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}static\mbox{]}}}}
\label{classRefTrieNode_a1edf09811a1bb304d748935306495cd2}


add a node to a subtree 

add subnet/payload to \hyperlink{protocolthe-p}{the} tree at $\ast$root.

\begin{DoxyReturn}{Returns}
a pointer to \hyperlink{protocolthe-p}{the} node.

a pointer to \hyperlink{protocolthe-p}{the} newly inserted node. 
\end{DoxyReturn}
\hypertarget{classRefTrieNode_a4bb6dcb2726b28a4c424945a6f981ae6}{
\index{RefTrieNode@{RefTrieNode}!is\_\-left@{is\_\-left}}
\index{is\_\-left@{is\_\-left}!RefTrieNode@{RefTrieNode}}
\subsubsection[{is\_\-left}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ bool {\bf RefTrieNode}$<$ A, Payload $>$::is\_\-left (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classRefTrieNode_a4bb6dcb2726b28a4c424945a6f981ae6}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} leftmost node under this node 
\end{DoxyReturn}
\hypertarget{classRefTrieNode_acf06961d9d45ba34432a6bd6d4ec11f2}{
\index{RefTrieNode@{RefTrieNode}!low@{low}}
\index{low@{low}!RefTrieNode@{RefTrieNode}}
\subsubsection[{low}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ A {\bf RefTrieNode}$<$ A, Payload $>$::low (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classRefTrieNode_acf06961d9d45ba34432a6bd6d4ec11f2}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} lowest address in a subtree which has a route. Search starting from left or right until a full node is found. 
\end{DoxyReturn}
\hypertarget{classRefTrieNode_a5e97c092b8f3153515aacc181976a08d}{
\index{RefTrieNode@{RefTrieNode}!lower\_\-bound@{lower\_\-bound}}
\index{lower\_\-bound@{lower\_\-bound}!RefTrieNode@{RefTrieNode}}
\subsubsection[{lower\_\-bound}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A , class Payload $>$ {\bf RefTrieNode}$<$ A, Payload $>$ $\ast$ {\bf RefTrieNode}$<$ A, Payload $>$::lower\_\-bound (
\begin{DoxyParamCaption}
\item[{const {\bf Key} \&}]{key}
\end{DoxyParamCaption}
)}}
\label{classRefTrieNode_a5e97c092b8f3153515aacc181976a08d}


Given a key, find \hyperlink{protocolthe-p}{the} node with that key and a payload. 

See \hyperlink{protocolthe-p}{the} comment in \hyperlink{protocolthe-p}{the} class definition.

If \hyperlink{protocolthe-p}{the} next doesn't exist or does not have a payload, find \hyperlink{protocolthe-p}{the} next node in \hyperlink{protocolthe-p}{the} iterator sequence. XXX check \hyperlink{protocolthe-p}{the} description. 

The documentation for this class was generated from the following file:\begin{DoxyCompactItemize}
\item 
/home/greearb/git/xorp.ct.github/xorp/libxorp/ref\_\-trie.hh\end{DoxyCompactItemize}
