\hypertarget{classInternalMessage}{
\section{InternalMessage$<$ A $>$ Class Template Reference}
\label{classInternalMessage}\index{InternalMessage@{InternalMessage}}
}


\hyperlink{classInternalMessage}{InternalMessage} is used to pass route changes between BGP route table classes.  




{\ttfamily \#include $<$internal\_\-message.hh$>$}

\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classInternalMessage_ab60ffae7e4d19d08066d36c1c4cf25b2}{
{\bfseries InternalMessage} (const \hyperlink{classSubnetRoute}{SubnetRoute}$<$ A $>$ $\ast$route, const \hyperlink{classPeerHandler}{PeerHandler} $\ast$origin\_\-peer, uint32\_\-t genid)}
\label{classInternalMessage_ab60ffae7e4d19d08066d36c1c4cf25b2}

\item 
\hypertarget{classInternalMessage_aa9c32e779a0c9c1f3ce4461a027296fd}{
{\bfseries InternalMessage} (const \hyperlink{classSubnetRoute}{SubnetRoute}$<$ A $>$ $\ast$route, FPAListRef pa\_\-list, const \hyperlink{classPeerHandler}{PeerHandler} $\ast$origin\_\-peer, uint32\_\-t genid)}
\label{classInternalMessage_aa9c32e779a0c9c1f3ce4461a027296fd}

\item 
\hypertarget{classInternalMessage_a0b65061d03da9d77b8018493583a437d}{
const \hyperlink{classIPNet}{IPNet}$<$ A $>$ \& {\bfseries net} () const }
\label{classInternalMessage_a0b65061d03da9d77b8018493583a437d}

\item 
\hypertarget{classInternalMessage_aefcc815ae11e5fdc245114c0bf4fa212}{
const \hyperlink{classSubnetRoute}{SubnetRoute}$<$ A $>$ $\ast$ {\bfseries route} () const }
\label{classInternalMessage_aefcc815ae11e5fdc245114c0bf4fa212}

\item 
\hypertarget{classInternalMessage_aa0613e1faeae77415c972bd48d18a482}{
const \hyperlink{classPeerHandler}{PeerHandler} $\ast$ {\bfseries origin\_\-peer} () const }
\label{classInternalMessage_aa0613e1faeae77415c972bd48d18a482}

\item 
\hypertarget{classInternalMessage_a65b9432545560dedf67ad499b5195bf1}{
const A \& {\bfseries nexthop} () const }
\label{classInternalMessage_a65b9432545560dedf67ad499b5195bf1}

\item 
\hypertarget{classInternalMessage_a831e04e2ac2093252dbb65c688a9a8b1}{
FPAListRef \& {\bfseries attributes} ()}
\label{classInternalMessage_a831e04e2ac2093252dbb65c688a9a8b1}

\item 
\hypertarget{classInternalMessage_a2c2ca23042d9c8034b3febeb1f21fa83}{
const FPAListRef \& {\bfseries const\_\-attributes} () const }
\label{classInternalMessage_a2c2ca23042d9c8034b3febeb1f21fa83}

\item 
\hypertarget{classInternalMessage_abfd7382ae9d5efb2cabf680ba40bbe7f}{
bool {\bfseries changed} () const }
\label{classInternalMessage_abfd7382ae9d5efb2cabf680ba40bbe7f}

\item 
\hypertarget{classInternalMessage_ab9cf12b68e90ade19f05169dd766ee2f}{
void {\bfseries set\_\-changed} ()}
\label{classInternalMessage_ab9cf12b68e90ade19f05169dd766ee2f}

\item 
\hypertarget{classInternalMessage_a1292f2544efbc6233f380500ad9502dc}{
void {\bfseries clear\_\-changed} () const }
\label{classInternalMessage_a1292f2544efbc6233f380500ad9502dc}

\item 
\hypertarget{classInternalMessage_a17ed4b19a42b92d6ecb1caf26a501118}{
bool {\bfseries copied} () const }
\label{classInternalMessage_a17ed4b19a42b92d6ecb1caf26a501118}

\item 
\hypertarget{classInternalMessage_a60d3ff5163a75ec399c0eacadc1f1bb3}{
void {\bfseries set\_\-copied} ()}
\label{classInternalMessage_a60d3ff5163a75ec399c0eacadc1f1bb3}

\item 
\hypertarget{classInternalMessage_a9cb2d264073f16a39dd659552acad8f0}{
void {\bfseries clear\_\-copied} () const }
\label{classInternalMessage_a9cb2d264073f16a39dd659552acad8f0}

\item 
\hypertarget{classInternalMessage_aabbfd6f35e440427be24b650b471ae6e}{
bool {\bfseries push} () const }
\label{classInternalMessage_aabbfd6f35e440427be24b650b471ae6e}

\item 
\hypertarget{classInternalMessage_a946ef841995d1c348d0ea78f5fd6e55a}{
void {\bfseries set\_\-push} ()}
\label{classInternalMessage_a946ef841995d1c348d0ea78f5fd6e55a}

\item 
\hypertarget{classInternalMessage_a13c246dc84480540c4e5b3e5a8ad4cc1}{
void {\bfseries clear\_\-push} ()}
\label{classInternalMessage_a13c246dc84480540c4e5b3e5a8ad4cc1}

\item 
\hypertarget{classInternalMessage_adb01d50b52bc1b7af107792a851ec35d}{
bool {\bfseries from\_\-previous\_\-peering} () const }
\label{classInternalMessage_adb01d50b52bc1b7af107792a851ec35d}

\item 
\hypertarget{classInternalMessage_a4ba542570ba40ab2e65934a348ff251a}{
void {\bfseries set\_\-from\_\-previous\_\-peering} ()}
\label{classInternalMessage_a4ba542570ba40ab2e65934a348ff251a}

\item 
\hypertarget{classInternalMessage_acffcf1d2d1f9f4c1587c58373aec189c}{
uint32\_\-t {\bfseries genid} () const }
\label{classInternalMessage_acffcf1d2d1f9f4c1587c58373aec189c}

\item 
\hypertarget{classInternalMessage_a91a1b81aa570e56c55129da22c131d2a}{
void {\bfseries inactivate} () const }
\label{classInternalMessage_a91a1b81aa570e56c55129da22c131d2a}

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

\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classInternalMessage_aa16d58ee8ffa0f8d17fb1b48510b0e01}{
const \hyperlink{classSubnetRoute}{SubnetRoute}$<$ A $>$ $\ast$ \hyperlink{classInternalMessage_aa16d58ee8ffa0f8d17fb1b48510b0e01}{\_\-subnet\_\-route}}
\label{classInternalMessage_aa16d58ee8ffa0f8d17fb1b48510b0e01}

\begin{DoxyCompactList}\small\item\em \hyperlink{protocolthe-p}{the} actual route data. \item\end{DoxyCompactList}\item 
FPAListRef \hyperlink{classInternalMessage_ac5f333218e54baa77f68a9b644caca9d}{\_\-attributes}
\begin{DoxyCompactList}\small\item\em \hyperlink{protocolthe-p}{the} path attribute list we use for fast accesses. \item\end{DoxyCompactList}\item 
\hypertarget{classInternalMessage_a918191422882e8af6eec289cbfdb870c}{
const \hyperlink{classPeerHandler}{PeerHandler} $\ast$ \hyperlink{classInternalMessage_a918191422882e8af6eec289cbfdb870c}{\_\-origin\_\-peer}}
\label{classInternalMessage_a918191422882e8af6eec289cbfdb870c}

\begin{DoxyCompactList}\small\item\em we need origin\_\-peer to make sure we don't send a route back to \hyperlink{protocolthe-p}{the} peer it came from, or send an IBGP route to an IBGP peer. \item\end{DoxyCompactList}\item 
\hypertarget{classInternalMessage_a4ac06428a51bdb8b571adf2bc1c0447e}{
bool \hyperlink{classInternalMessage_a4ac06428a51bdb8b571adf2bc1c0447e}{\_\-changed}}
\label{classInternalMessage_a4ac06428a51bdb8b571adf2bc1c0447e}

\begin{DoxyCompactList}\small\item\em changed indicates that \hyperlink{protocolthe-p}{the} route data has been modified since \hyperlink{protocolthe-p}{the} route was last stored (and so needs storing by a \hyperlink{classCacheTable}{CacheTable}). \item\end{DoxyCompactList}\item 
\hypertarget{classInternalMessage_a19423c4d9bb2b0abad6d5f073f5c30be}{
bool \hyperlink{classInternalMessage_a19423c4d9bb2b0abad6d5f073f5c30be}{\_\-copied}}
\label{classInternalMessage_a19423c4d9bb2b0abad6d5f073f5c30be}

\begin{DoxyCompactList}\small\item\em copied indicates that \hyperlink{protocolthe-p}{the} subnet route data has been copied since \hyperlink{protocolthe-p}{the} route was last stored (and so needs freeing by \hyperlink{protocolthe-p}{the} final recipient) \item\end{DoxyCompactList}\item 
\hypertarget{classInternalMessage_aa35819b9fa41703e85b48433831b1c3e}{
uint32\_\-t \hyperlink{classInternalMessage_aa35819b9fa41703e85b48433831b1c3e}{\_\-genid}}
\label{classInternalMessage_aa35819b9fa41703e85b48433831b1c3e}

\begin{DoxyCompactList}\small\item\em genid is \hyperlink{protocolthe-p}{the} generation ID from \hyperlink{protocolthe-p}{the} RibIn, if known, or zero if it's not known. \item\end{DoxyCompactList}\item 
\hypertarget{classInternalMessage_ac06b4730202224e9c93f3996e0d43fb7}{
bool \hyperlink{classInternalMessage_ac06b4730202224e9c93f3996e0d43fb7}{\_\-push}}
\label{classInternalMessage_ac06b4730202224e9c93f3996e0d43fb7}

\begin{DoxyCompactList}\small\item\em push indicates that this is \hyperlink{protocolthe-p}{the} last route in a batch, so \hyperlink{protocolthe-p}{the} push to peers is implicit. \item\end{DoxyCompactList}\item 
\hypertarget{classInternalMessage_ad803a41884e3c3f2a30aff8d9e57d1c1}{
bool \hyperlink{classInternalMessage_ad803a41884e3c3f2a30aff8d9e57d1c1}{\_\-from\_\-previous\_\-peering}}
\label{classInternalMessage_ad803a41884e3c3f2a30aff8d9e57d1c1}

\begin{DoxyCompactList}\small\item\em from\_\-previous\_\-peering is set on messages where \hyperlink{protocolthe-p}{the} deleted route originates from a previous peering that has now gone down. \item\end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
\subsubsection*{template$<$class A$>$ class InternalMessage$<$ A $>$}

\hyperlink{classInternalMessage}{InternalMessage} is used to pass route changes between BGP route table classes. XORP BGP is implemented as a pipelined series of route\_\-tables, starting with a \hyperlink{classRibInTable}{RibInTable} for each peering, converging on a \hyperlink{classDecisionTable}{DecisionTable} to decide which competing route is prefered, and then fanning out again to a \hyperlink{classRibOutTable}{RibOutTable} for each peer. \hyperlink{classRouting}{Routing} changes such as add\_\-route, delete\_\-route, and replace\_\-route propagate through this pipeline. The \char`\"{}payload\char`\"{} of these changes is an \hyperlink{classInternalMessage}{InternalMessage}, which contains \hyperlink{protocolthe-p}{the} route itself, \hyperlink{protocolthe-p}{the} peering from which this route originated, and \hyperlink{protocolthe-p}{the} generation ID of \hyperlink{protocolthe-p}{the} RibIn at that peering. 

\subsection{Member Data Documentation}
\hypertarget{classInternalMessage_ac5f333218e54baa77f68a9b644caca9d}{
\index{InternalMessage@{InternalMessage}!\_\-attributes@{\_\-attributes}}
\index{\_\-attributes@{\_\-attributes}!InternalMessage@{InternalMessage}}
\subsubsection[{\_\-attributes}]{\setlength{\rightskip}{0pt plus 5cm}template$<$class A$>$ FPAListRef {\bf InternalMessage}$<$ A $>$::{\bf \_\-attributes}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{classInternalMessage_ac5f333218e54baa77f68a9b644caca9d}


\hyperlink{protocolthe-p}{the} path attribute list we use for fast accesses. 

This is reference counted so we don't need to worry about freeing it when we copy it from message to message. 

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