\hypertarget{classPort}{
\section{Port$<$ A $>$ Class Template Reference}
\label{classPort}\index{Port@{Port}}
}


RIP \hyperlink{classPort}{Port}.  




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

Inheritance diagram for Port$<$ A $>$:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=2.349650cm]{classPort}
\end{center}
\end{figure}
\subsection*{Public Types}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classPort_aef117dae93fa5d0f9650dd9342c2bd25}{
typedef A {\bfseries Addr}}
\label{classPort_aef117dae93fa5d0f9650dd9342c2bd25}

\item 
\hypertarget{classPort_af7872536604b3699497fecb538210be1}{
typedef list$<$ \hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$ $>$ {\bfseries PeerList}}
\label{classPort_af7872536604b3699497fecb538210be1}

\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classPort_a5a47b57364995dc58aae22bd6635aec7}{
{\bfseries Port} (\hyperlink{classPortManagerBase}{PortManagerBase}$<$ A $>$ \&manager)}
\label{classPort_a5a47b57364995dc58aae22bd6635aec7}

\item 
\hypertarget{classPort_ad36b602549ac8291e679fcb7a5b7acc2}{
\hyperlink{classPortManagerBase}{PortManagerBase}$<$ A $>$ \& {\bfseries port\_\-manager} ()}
\label{classPort_ad36b602549ac8291e679fcb7a5b7acc2}

\item 
void \hyperlink{classPort_a1478db3be319e6c01da61582f5e83b62}{set\_\-enabled} (bool en)
\begin{DoxyCompactList}\small\item\em Set enabled state. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a74285542970471389efd1b250656c714}{
bool \hyperlink{classPort_a74285542970471389efd1b250656c714}{enabled} () const }
\label{classPort_a74285542970471389efd1b250656c714}

\begin{DoxyCompactList}\small\item\em Get enabled state. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a55081817b5749f625e354efce2e8e6cc}{
\hyperlink{classPortTimerConstants}{PortTimerConstants} \& \hyperlink{classPort_a55081817b5749f625e354efce2e8e6cc}{constants} ()}
\label{classPort_a55081817b5749f625e354efce2e8e6cc}

\begin{DoxyCompactList}\small\item\em Get timer constants in use for routes received on this port. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_ab3fc3296ddaa193d2c4b162903f290be}{
const \hyperlink{classPortTimerConstants}{PortTimerConstants} \& \hyperlink{classPort_ab3fc3296ddaa193d2c4b162903f290be}{constants} () const }
\label{classPort_ab3fc3296ddaa193d2c4b162903f290be}

\begin{DoxyCompactList}\small\item\em Get timer constants in use for routes received on this port. \item\end{DoxyCompactList}\item 
\hyperlink{classPortAFSpecState}{PortAFSpecState}$<$ A $>$ \& \hyperlink{classPort_a9907e6d475b15d90132eaebc68c928dc}{af\_\-state} ()
\begin{DoxyCompactList}\small\item\em Get \hyperlink{structAddress}{Address} Family specific state associated with port. \item\end{DoxyCompactList}\item 
const \hyperlink{classPortAFSpecState}{PortAFSpecState}$<$ A $>$ \& \hyperlink{classPort_a5e476414cb3fcfc43e9b9d7943a8f282}{af\_\-state} () const 
\begin{DoxyCompactList}\small\item\em Get \hyperlink{structAddress}{Address} Family specific state associated with port. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a8482748ae385d7631837560ae3be0c51}{
uint32\_\-t \hyperlink{classPort_a8482748ae385d7631837560ae3be0c51}{cost} () const }
\label{classPort_a8482748ae385d7631837560ae3be0c51}

\begin{DoxyCompactList}\small\item\em Get cost metric associated with \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a769282839d86445b7b3dc119b48d6d49}{
void \hyperlink{classPort_a769282839d86445b7b3dc119b48d6d49}{set\_\-cost} (uint32\_\-t cost)}
\label{classPort_a769282839d86445b7b3dc119b48d6d49}

\begin{DoxyCompactList}\small\item\em Set cost metric associated with \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_aac06d2c94a3963fb37f3d07d845f2c08}{
const RipHorizon \& \hyperlink{classPort_aac06d2c94a3963fb37f3d07d845f2c08}{horizon} () const }
\label{classPort_aac06d2c94a3963fb37f3d07d845f2c08}

\begin{DoxyCompactList}\small\item\em Get horizon type associated with \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_aee86d7ffc7f25050b6e7a40731779345}{set\_\-horizon} (const RipHorizon \&h)
\begin{DoxyCompactList}\small\item\em Set horizon type associated with \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_ad6c7716577ccfe8339bee764173fb508}{advertise} () const 
\begin{DoxyCompactList}\small\item\em Determine whether \hyperlink{classPort}{Port} address should be advertised. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a1a349a66b05f5667f8d11fadef5956af}{set\_\-advertise} (bool en)
\begin{DoxyCompactList}\small\item\em Set \hyperlink{classPort}{Port} advertisement status. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_ac3353ed4442c2ec0f17327ca59b17888}{advertise\_\-default\_\-route} () const 
\begin{DoxyCompactList}\small\item\em Include default route in RIP response messages. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_aea1a83309c849638061fad88482d20e7}{set\_\-advertise\_\-default\_\-route} (bool en)
\begin{DoxyCompactList}\small\item\em Configure whether default route is advertised in RIP response messages. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_a84989c4a7542162d632811dbb14e78f4}{accept\_\-default\_\-route} () const 
\begin{DoxyCompactList}\small\item\em \hyperlink{classAccept}{Accept} default route if found in RIP response messages. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a1e2e7fcd8074166f36cc5ba09b20932c}{set\_\-accept\_\-default\_\-route} (bool en)
\begin{DoxyCompactList}\small\item\em \hyperlink{classAccept}{Accept} default route if found in RIP response messages. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_af04c2e3b352e04bcefd25809df3ca8c7}{passive} () const 
\begin{DoxyCompactList}\small\item\em \hyperlink{classAccept}{Accept} routes, but do not advertise them. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a51bd1b871d74b61a0ba8cca18263a2bc}{set\_\-passive} (bool passive)
\begin{DoxyCompactList}\small\item\em \hyperlink{classAccept}{Accept} routes, but do not advertise them. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_ae334a25b6350c220c1354646e563c245}{accept\_\-non\_\-rip\_\-requests} () const 
\begin{DoxyCompactList}\small\item\em \hyperlink{classAccept}{Accept} and respond to non-\/RIP requests. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_afaef9a5a602948031236205b244f0a0e}{set\_\-accept\_\-non\_\-rip\_\-requests} (bool en)
\begin{DoxyCompactList}\small\item\em \hyperlink{classAccept}{Accept} and respond to non-\/RIP requests. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_abc9362a6d2347a01b8ea7e36e4f2accd}{
const PeerList \& \hyperlink{classPort_abc9362a6d2347a01b8ea7e36e4f2accd}{peers} () const }
\label{classPort_abc9362a6d2347a01b8ea7e36e4f2accd}

\begin{DoxyCompactList}\small\item\em Get Peers associated with this \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
PeerList \& \hyperlink{classPort_a8d210c0bbc179ce6ec83878cc097b800}{peers} ()
\begin{DoxyCompactList}\small\item\em Get Peers associated with this \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a4ea3bf72adb362b9d3af45ab3030066f}{
const \hyperlink{structPortCounters}{PortCounters} \& \hyperlink{classPort_a4ea3bf72adb362b9d3af45ab3030066f}{counters} () const }
\label{classPort_a4ea3bf72adb362b9d3af45ab3030066f}

\begin{DoxyCompactList}\small\item\em Get counters associated with \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a9d17b7503934baae1dca7e38a0cfc609}{
\hyperlink{structPortCounters}{PortCounters} \& \hyperlink{classPort_a9d17b7503934baae1dca7e38a0cfc609}{counters} ()}
\label{classPort_a9d17b7503934baae1dca7e38a0cfc609}

\begin{DoxyCompactList}\small\item\em Get counters associated with \hyperlink{classPort}{Port}. \item\end{DoxyCompactList}\item 
const \hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$ \hyperlink{classPort_ad5a17f795e92df2fa8121449feb41cd9}{peer} (const Addr \&addr) const 
\begin{DoxyCompactList}\small\item\em Get \hyperlink{classPeer}{Peer} identified by address. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a7d10dfec4e08ac5f63d535c41fb8354a}{
void \hyperlink{classPort_a7d10dfec4e08ac5f63d535c41fb8354a}{set\_\-max\_\-packet\_\-buffer\_\-bytes} (uint32\_\-t max\_\-bytes)}
\label{classPort_a7d10dfec4e08ac5f63d535c41fb8354a}

\begin{DoxyCompactList}\small\item\em Set \hyperlink{protocolthe-p}{the} maximum packet buffer size. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a1a0fe070eaf6e77a19acf5689a1395a6}{
uint32\_\-t \hyperlink{classPort_a1a0fe070eaf6e77a19acf5689a1395a6}{set\_\-max\_\-packet\_\-buffer\_\-bytes} () const }
\label{classPort_a1a0fe070eaf6e77a19acf5689a1395a6}

\begin{DoxyCompactList}\small\item\em Get \hyperlink{protocolthe-p}{the} maximum packet buffer size. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a07e4a4c28cc6c9c171609a2959d0ece6}{
uint32\_\-t \hyperlink{classPort_a07e4a4c28cc6c9c171609a2959d0ece6}{packet\_\-buffer\_\-bytes} () const }
\label{classPort_a07e4a4c28cc6c9c171609a2959d0ece6}

\begin{DoxyCompactList}\small\item\em Get \hyperlink{protocolthe-p}{the} current number of bytes buffered in RIP packets. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a90af001bf66624efa64c3f374e905c04}{
void \hyperlink{classPort_a90af001bf66624efa64c3f374e905c04}{reschedule\_\-dummy\_\-timer} ()}
\label{classPort_a90af001bf66624efa64c3f374e905c04}

\begin{DoxyCompactList}\small\item\em A dummy method to reschedule a non-\/existing timer. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a84df0a0dd7ed237b0708328a2d6d7d86}{reschedule\_\-request\_\-table\_\-timer} ()
\begin{DoxyCompactList}\small\item\em Reschedule request table timer. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_aedc09a3de9ef9d39168ecf8d15656408}{
void \hyperlink{classPort_aedc09a3de9ef9d39168ecf8d15656408}{push\_\-packets} ()}
\label{classPort_aedc09a3de9ef9d39168ecf8d15656408}

\begin{DoxyCompactList}\small\item\em If I/O handler is not already sending a packet, take a packet from packet queue and send it. \item\end{DoxyCompactList}\item 
pair$<$ A, uint16\_\-t $>$ \hyperlink{classPort_adfa2be5f29a7754e950c2283b6ce45d4}{route\_\-policy} (const \hyperlink{classRouteEntry}{RouteEntry}$<$ A $>$ \&re) const 
\begin{DoxyCompactList}\small\item\em Check policy on route. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_ae2b942d2a3d6fe5aad736f9551b5c6cb}{port\_\-io\_\-send\_\-completion} (bool success)
\begin{DoxyCompactList}\small\item\em \hyperlink{structSend}{Send} completion notification. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_adcb68aa0c998aac760271de1843655ee}{port\_\-io\_\-receive} (const Addr \&src\_\-addr, uint16\_\-t src\_\-port, const uint8\_\-t $\ast$rip\_\-packet, const size\_\-t rip\_\-packet\_\-bytes)
\begin{DoxyCompactList}\small\item\em Receive RIP packet. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a00f21335334571c30ac140273cd2f987}{port\_\-io\_\-enabled\_\-change} (bool en)
\begin{DoxyCompactList}\small\item\em Notification that PortIO enabled state has changed. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Protected Member Functions}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{classPort_a6314ca57c8b6082d35bc2ae8a10f325c}{start\_\-request\_\-table\_\-timer} ()
\begin{DoxyCompactList}\small\item\em Start request table timer. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a67f2856d41c3af56960c9e1c8a101252}{
void \hyperlink{classPort_a67f2856d41c3af56960c9e1c8a101252}{stop\_\-request\_\-table\_\-timer} ()}
\label{classPort_a67f2856d41c3af56960c9e1c8a101252}

\begin{DoxyCompactList}\small\item\em Stop request table timer. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_a83704b041678e22740e437db2242649e}{request\_\-table} ()
\begin{DoxyCompactList}\small\item\em \hyperlink{structSend}{Send} request packet. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_aee9490742952d2277cf69e537ffd1f8d}{request\_\-table\_\-timeout} ()
\begin{DoxyCompactList}\small\item\em \hyperlink{structSend}{Send} request packet if there are no peers. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a17315c546806fc71f2fab53a24b556ec}{start\_\-peer\_\-gc\_\-timer} ()
\begin{DoxyCompactList}\small\item\em Start periodic timer to garbage collect peers. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_ae2d4343154a778a8480f45119f302359}{peer\_\-gc\_\-timeout} ()
\begin{DoxyCompactList}\small\item\em Poll peers and remove those with no routes. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a9e0bc0b61743f88f84091a5a961066e8}{kill\_\-peer\_\-routes} ()
\begin{DoxyCompactList}\small\item\em Kill peer routes. \item\end{DoxyCompactList}\item 
\hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$ \hyperlink{classPort_af75a7ef13d52bfc009f0ada6e62b4d21}{peer} (const Addr \&addr)
\begin{DoxyCompactList}\small\item\em Get \hyperlink{classPeer}{Peer} identified by address. \item\end{DoxyCompactList}\item 
\hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$ \hyperlink{classPort_aa8e5723010dcc315b67ba2b1262c33b9}{create\_\-peer} (const Addr \&addr)
\begin{DoxyCompactList}\small\item\em Create \hyperlink{classPeer}{Peer}. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_ac606fe7aac88bcc3f1a634c76a2af419}{record\_\-packet} (\hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$p)
\begin{DoxyCompactList}\small\item\em Record packet arrival. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_ac9ee77b89dfab4a71e84a7aa4b586b3d}{
void \hyperlink{classPort_ac9ee77b89dfab4a71e84a7aa4b586b3d}{record\_\-response\_\-packet} (\hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$p)}
\label{classPort_ac9ee77b89dfab4a71e84a7aa4b586b3d}

\begin{DoxyCompactList}\small\item\em Record response packet arrival. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a230660bcb61aa7b2f85027115b8e4ab5}{
void \hyperlink{classPort_a230660bcb61aa7b2f85027115b8e4ab5}{record\_\-request\_\-packet} (\hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$p)}
\label{classPort_a230660bcb61aa7b2f85027115b8e4ab5}

\begin{DoxyCompactList}\small\item\em Record request packet arrival. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a655cbc2caa0ac81021dbba3a089552bf}{record\_\-bad\_\-packet} (const string \&why, const Addr \&addr, uint16\_\-t port, \hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$p)
\begin{DoxyCompactList}\small\item\em Record bad packet. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a7de470bff82a3c30fe067955a65a2b2f}{
void \hyperlink{classPort_a7de470bff82a3c30fe067955a65a2b2f}{record\_\-bad\_\-auth\_\-packet} (const string \&why, const Addr \&addr, uint16\_\-t port, \hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$p)}
\label{classPort_a7de470bff82a3c30fe067955a65a2b2f}

\begin{DoxyCompactList}\small\item\em Record bad authentication packet. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_a8ed1ad92bd3dfed46720f0cde00a2e5a}{record\_\-bad\_\-route} (const string \&why, const Addr \&src, uint16\_\-t port, \hyperlink{classPeer}{Peer}$<$ A $>$ $\ast$p)
\begin{DoxyCompactList}\small\item\em Record bad route. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_ac0ab01fa52ce0c697d1636fd7a634d4b}{
void \hyperlink{classPort_ac0ab01fa52ce0c697d1636fd7a634d4b}{parse\_\-request} (const Addr \&src\_\-addr, uint16\_\-t rc\_\-port, const uint8\_\-t $\ast$entries\_\-ptr, uint32\_\-t n\_\-entries)}
\label{classPort_ac0ab01fa52ce0c697d1636fd7a634d4b}

\begin{DoxyCompactList}\small\item\em Parse request message. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a06b928170cf43306d3d09838fec7ab33}{
void \hyperlink{classPort_a06b928170cf43306d3d09838fec7ab33}{parse\_\-response} (const Addr \&src\_\-addr, uint16\_\-t src\_\-port, const uint8\_\-t $\ast$entries\_\-ptr, uint32\_\-t n\_\-entries)}
\label{classPort_a06b928170cf43306d3d09838fec7ab33}

\begin{DoxyCompactList}\small\item\em Parse response message. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a59d2cd23993b9d1d5886236724274cb2}{
void \hyperlink{classPort_a59d2cd23993b9d1d5886236724274cb2}{block\_\-queries} ()}
\label{classPort_a59d2cd23993b9d1d5886236724274cb2}

\begin{DoxyCompactList}\small\item\em Block route queries for amount of time determined by \hyperlink{classPortTimerConstants_ad7bdd2f31508f5af9195ea4f6fc84f70}{PortTimerConstants::interquery\_\-delay\_\-ms()}. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a6df14f1bc288f4ca63362173b38a7e8d}{
bool \hyperlink{classPort_a6df14f1bc288f4ca63362173b38a7e8d}{queries\_\-blocked} () const }
\label{classPort_a6df14f1bc288f4ca63362173b38a7e8d}

\begin{DoxyCompactList}\small\item\em Determine whether queries are currently blocked and should be discarded. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_a9933299129c304441e3801c08d463646}{
void \hyperlink{classPort_a9933299129c304441e3801c08d463646}{unsolicited\_\-response\_\-timeout} ()}
\label{classPort_a9933299129c304441e3801c08d463646}

\begin{DoxyCompactList}\small\item\em Unsolicited update output timer timeout. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_af2f33ffd665ebb2f75f97ab83dcdb506}{
void \hyperlink{classPort_af2f33ffd665ebb2f75f97ab83dcdb506}{triggered\_\-update\_\-timeout} ()}
\label{classPort_af2f33ffd665ebb2f75f97ab83dcdb506}

\begin{DoxyCompactList}\small\item\em Triggered update timeout. \item\end{DoxyCompactList}\item 
bool \hyperlink{classPort_a0bd3d1d98032b5ac42e6aca3c3f4e029}{output\_\-allowed} () const 
\begin{DoxyCompactList}\small\item\em Query output process policy. \item\end{DoxyCompactList}\item 
\hypertarget{classPort_af73645dac4cb524f0b952e0467249031}{
void \hyperlink{classPort_af73645dac4cb524f0b952e0467249031}{start\_\-stop\_\-output\_\-processing} ()}
\label{classPort_af73645dac4cb524f0b952e0467249031}

\begin{DoxyCompactList}\small\item\em Check whether output is allowed and start or stop output processing accordingly. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_aefa4c970dac0377c992785804e5ef5b6}{start\_\-output\_\-processing} ()
\begin{DoxyCompactList}\small\item\em Start output processing. \item\end{DoxyCompactList}\item 
void \hyperlink{classPort_aae39907270f2b10e3ff5e99f48e9e819}{stop\_\-output\_\-processing} ()
\begin{DoxyCompactList}\small\item\em Stop output processing. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Protected Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classPort_ac5fe937f7de20b23fb37a88b8923002c}{
\hyperlink{classPortManagerBase}{PortManagerBase}$<$ A $>$ \& {\bfseries \_\-pm}}
\label{classPort_ac5fe937f7de20b23fb37a88b8923002c}

\item 
\hypertarget{classPort_ac4fcb040c3959acdbac3c16cceeb3dcd}{
\hyperlink{classPortAFSpecState}{PortAFSpecState}$<$ A $>$ {\bfseries \_\-af\_\-state}}
\label{classPort_ac4fcb040c3959acdbac3c16cceeb3dcd}

\item 
\hypertarget{classPort_ae0b9b5201b78d490a55814b4316235e5}{
PeerList {\bfseries \_\-peers}}
\label{classPort_ae0b9b5201b78d490a55814b4316235e5}

\item 
\hypertarget{classPort_a3b85db907f8dced879a71c90fa9fae2b}{
\hyperlink{classXorpTimer}{XorpTimer} {\bfseries \_\-rt\_\-timer}}
\label{classPort_a3b85db907f8dced879a71c90fa9fae2b}

\item 
\hypertarget{classPort_a69369b57ea6bc39d8bbe0906637d3135}{
\hyperlink{classXorpTimer}{XorpTimer} {\bfseries \_\-gc\_\-timer}}
\label{classPort_a69369b57ea6bc39d8bbe0906637d3135}

\item 
\hypertarget{classPort_a7e80e05ac254c0f5411fa35295824801}{
\hyperlink{classXorpTimer}{XorpTimer} {\bfseries \_\-ur\_\-timer}}
\label{classPort_a7e80e05ac254c0f5411fa35295824801}

\item 
\hypertarget{classPort_aa97df33eec2e4576244323bed10509f7}{
\hyperlink{classXorpTimer}{XorpTimer} {\bfseries \_\-tu\_\-timer}}
\label{classPort_aa97df33eec2e4576244323bed10509f7}

\item 
\hypertarget{classPort_a20a63503a93da3c84a4b9632881696e7}{
\hyperlink{classXorpTimer}{XorpTimer} {\bfseries \_\-query\_\-blocked\_\-timer}}
\label{classPort_a20a63503a93da3c84a4b9632881696e7}

\item 
\hypertarget{classPort_aba89657e2a53069357774aea5e2e1f71}{
bool {\bfseries \_\-en}}
\label{classPort_aba89657e2a53069357774aea5e2e1f71}

\item 
\hypertarget{classPort_a5aecd9bd06757306d20d449cfc3f86e0}{
uint32\_\-t {\bfseries \_\-cost}}
\label{classPort_a5aecd9bd06757306d20d449cfc3f86e0}

\item 
\hypertarget{classPort_a73c30f3145033d8f83d767108f8fd674}{
RipHorizon {\bfseries \_\-horizon}}
\label{classPort_a73c30f3145033d8f83d767108f8fd674}

\item 
\hypertarget{classPort_ad0612a3108827e2cc65736a5fb55a688}{
bool {\bfseries \_\-advertise}}
\label{classPort_ad0612a3108827e2cc65736a5fb55a688}

\item 
\hypertarget{classPort_ad509528eadb10b2948a40dea7613ab69}{
bool {\bfseries \_\-adv\_\-def\_\-rt}}
\label{classPort_ad509528eadb10b2948a40dea7613ab69}

\item 
\hypertarget{classPort_a2992be08385183183cdae864f5290475}{
bool {\bfseries \_\-acc\_\-def\_\-rt}}
\label{classPort_a2992be08385183183cdae864f5290475}

\item 
\hypertarget{classPort_a3a0426b49fc7fcd718fe5eda5a385848}{
bool {\bfseries \_\-passive}}
\label{classPort_a3a0426b49fc7fcd718fe5eda5a385848}

\item 
\hypertarget{classPort_a335478bd281d0185dc9abb3db32864b5}{
bool {\bfseries \_\-acc\_\-non\_\-rip\_\-reqs}}
\label{classPort_a335478bd281d0185dc9abb3db32864b5}

\item 
\hypertarget{classPort_a97434a7cc322398d75b7cf9ab5cde018}{
\hyperlink{classPacketQueue}{PacketQueue}$<$ A $>$ $\ast$ {\bfseries \_\-packet\_\-queue}}
\label{classPort_a97434a7cc322398d75b7cf9ab5cde018}

\item 
\hypertarget{classPort_ad6d83c7abaf648763d6a27d971e59dc6}{
\hyperlink{classPortTimerConstants}{PortTimerConstants} {\bfseries \_\-constants}}
\label{classPort_ad6d83c7abaf648763d6a27d971e59dc6}

\item 
\hypertarget{classPort_a2b2c181f96fc2de671a47d6b1bec9227}{
\hyperlink{structPortCounters}{PortCounters} {\bfseries \_\-counters}}
\label{classPort_a2b2c181f96fc2de671a47d6b1bec9227}

\item 
\hypertarget{classPort_aac84497419a6d4c6d7b469f4a7e06647}{
\hyperlink{classOutputTable}{OutputTable}$<$ A $>$ $\ast$ {\bfseries \_\-ur\_\-out}}
\label{classPort_aac84497419a6d4c6d7b469f4a7e06647}

\item 
\hypertarget{classPort_a059c721a68d67582b40aa3f386de3d17}{
\hyperlink{classOutputUpdates}{OutputUpdates}$<$ A $>$ $\ast$ {\bfseries \_\-tu\_\-out}}
\label{classPort_a059c721a68d67582b40aa3f386de3d17}

\item 
\hypertarget{classPort_a85e9b54b97e1c38fa538b799376317c5}{
\hyperlink{classOutputTable}{OutputTable}$<$ A $>$ $\ast$ {\bfseries \_\-su\_\-out}}
\label{classPort_a85e9b54b97e1c38fa538b799376317c5}

\end{DoxyCompactItemize}


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

RIP \hyperlink{classPort}{Port}. A RIP \hyperlink{classPort}{Port} is an origin and sink of RIP packets. It is uniquely identified by \hyperlink{protocolthe-p}{the} tuplet of $<$interface, virtual interface, address$>$. The \hyperlink{classPort}{Port} sends and receives RIP packets via an attached \hyperlink{classPort}{Port} \hyperlink{classIO}{IO} object (\hyperlink{classPortIOBase}{PortIOBase}). The \hyperlink{classPort}{Port} contains a list of Peers (\hyperlink{classPeer}{Peer}) that it has received communication on and is responsible for updating information sent by peers in \hyperlink{protocolthe-p}{the} RIP route database (\hyperlink{classRouteDB}{RouteDB}). 

\subsection{Member Function Documentation}
\hypertarget{classPort_a84989c4a7542162d632811dbb14e78f4}{
\index{Port@{Port}!accept\_\-default\_\-route@{accept\_\-default\_\-route}}
\index{accept\_\-default\_\-route@{accept\_\-default\_\-route}!Port@{Port}}
\subsubsection[{accept\_\-default\_\-route}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ bool {\bf Port}$<$ A $>$::accept\_\-default\_\-route (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_a84989c4a7542162d632811dbb14e78f4}


\hyperlink{classAccept}{Accept} default route if found in RIP response messages. 

\begin{DoxyReturn}{Returns}
true if default route should be accepted. 
\end{DoxyReturn}
\hypertarget{classPort_ae334a25b6350c220c1354646e563c245}{
\index{Port@{Port}!accept\_\-non\_\-rip\_\-requests@{accept\_\-non\_\-rip\_\-requests}}
\index{accept\_\-non\_\-rip\_\-requests@{accept\_\-non\_\-rip\_\-requests}!Port@{Port}}
\subsubsection[{accept\_\-non\_\-rip\_\-requests}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ bool {\bf Port}$<$ A $>$::accept\_\-non\_\-rip\_\-requests (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_ae334a25b6350c220c1354646e563c245}


\hyperlink{classAccept}{Accept} and respond to non-\/RIP requests. 

Testing and Debugging tools typically send requests from non-\/RIP IP ports. \hypertarget{classPort_ad6c7716577ccfe8339bee764173fb508}{
\index{Port@{Port}!advertise@{advertise}}
\index{advertise@{advertise}!Port@{Port}}
\subsubsection[{advertise}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ bool {\bf Port}$<$ A $>$::advertise (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_ad6c7716577ccfe8339bee764173fb508}


Determine whether \hyperlink{classPort}{Port} address should be advertised. 

\begin{DoxyReturn}{Returns}
true if port should be advertised to other hosts, false otherwise. 
\end{DoxyReturn}
\hypertarget{classPort_ac3353ed4442c2ec0f17327ca59b17888}{
\index{Port@{Port}!advertise\_\-default\_\-route@{advertise\_\-default\_\-route}}
\index{advertise\_\-default\_\-route@{advertise\_\-default\_\-route}!Port@{Port}}
\subsubsection[{advertise\_\-default\_\-route}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ bool {\bf Port}$<$ A $>$::advertise\_\-default\_\-route (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_ac3353ed4442c2ec0f17327ca59b17888}


Include default route in RIP response messages. 

\begin{DoxyReturn}{Returns}
true if default route is advertised. 
\end{DoxyReturn}
\hypertarget{classPort_a5e476414cb3fcfc43e9b9d7943a8f282}{
\index{Port@{Port}!af\_\-state@{af\_\-state}}
\index{af\_\-state@{af\_\-state}!Port@{Port}}
\subsubsection[{af\_\-state}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ const {\bf PortAFSpecState}$<$A$>$\& {\bf Port}$<$ A $>$::af\_\-state (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_a5e476414cb3fcfc43e9b9d7943a8f282}


Get \hyperlink{structAddress}{Address} Family specific state associated with port. 

This is state that only has meaning within \hyperlink{protocolthe-p}{the} IP address family. \hypertarget{classPort_a9907e6d475b15d90132eaebc68c928dc}{
\index{Port@{Port}!af\_\-state@{af\_\-state}}
\index{af\_\-state@{af\_\-state}!Port@{Port}}
\subsubsection[{af\_\-state}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ {\bf PortAFSpecState}$<$A$>$\& {\bf Port}$<$ A $>$::af\_\-state (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_a9907e6d475b15d90132eaebc68c928dc}


Get \hyperlink{structAddress}{Address} Family specific state associated with port. 

This is state that only has meaning within \hyperlink{protocolthe-p}{the} IP address family. \hypertarget{classPort_aa8e5723010dcc315b67ba2b1262c33b9}{
\index{Port@{Port}!create\_\-peer@{create\_\-peer}}
\index{create\_\-peer@{create\_\-peer}!Port@{Port}}
\subsubsection[{create\_\-peer}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ {\bf Peer}$<$ A $>$ $\ast$ {\bf Port}$<$ A $>$::create\_\-peer (
\begin{DoxyParamCaption}
\item[{const Addr \&}]{addr}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_aa8e5723010dcc315b67ba2b1262c33b9}


Create \hyperlink{classPeer}{Peer}. 

\begin{DoxyReturn}{Returns}
pointer to \hyperlink{classPeer}{Peer} if created, 0 on failure or peer already exists. 
\end{DoxyReturn}
\hypertarget{classPort_a9e0bc0b61743f88f84091a5a961066e8}{
\index{Port@{Port}!kill\_\-peer\_\-routes@{kill\_\-peer\_\-routes}}
\index{kill\_\-peer\_\-routes@{kill\_\-peer\_\-routes}!Port@{Port}}
\subsubsection[{kill\_\-peer\_\-routes}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::kill\_\-peer\_\-routes (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_a9e0bc0b61743f88f84091a5a961066e8}


Kill peer routes. 

Change cost of routes learned from peers to infinity. Typically called when port instance is disabled or io system reports that it is not enabled. \hypertarget{classPort_a0bd3d1d98032b5ac42e6aca3c3f4e029}{
\index{Port@{Port}!output\_\-allowed@{output\_\-allowed}}
\index{output\_\-allowed@{output\_\-allowed}!Port@{Port}}
\subsubsection[{output\_\-allowed}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ bool {\bf Port}$<$ A $>$::output\_\-allowed (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_a0bd3d1d98032b5ac42e6aca3c3f4e029}


Query output process policy. 

Check whether instance is enabled, whether it is active or passive, and whether \hyperlink{protocolthe-p}{the} associated I/O object is enabled. \hypertarget{classPort_af04c2e3b352e04bcefd25809df3ca8c7}{
\index{Port@{Port}!passive@{passive}}
\index{passive@{passive}!Port@{Port}}
\subsubsection[{passive}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ bool {\bf Port}$<$ A $>$::passive (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_af04c2e3b352e04bcefd25809df3ca8c7}


\hyperlink{classAccept}{Accept} routes, but do not advertise them. 

\begin{DoxyReturn}{Returns}
true if this port is passive. 
\end{DoxyReturn}
\hypertarget{classPort_af75a7ef13d52bfc009f0ada6e62b4d21}{
\index{Port@{Port}!peer@{peer}}
\index{peer@{peer}!Port@{Port}}
\subsubsection[{peer}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ {\bf Peer}$<$ A $>$ $\ast$ {\bf Port}$<$ A $>$::peer (
\begin{DoxyParamCaption}
\item[{const Addr \&}]{addr}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_af75a7ef13d52bfc009f0ada6e62b4d21}


Get \hyperlink{classPeer}{Peer} identified by address. 

\begin{DoxyReturn}{Returns}
pointer to \hyperlink{classPeer}{Peer} on success, 0 otherwise. 
\end{DoxyReturn}
\hypertarget{classPort_ad5a17f795e92df2fa8121449feb41cd9}{
\index{Port@{Port}!peer@{peer}}
\index{peer@{peer}!Port@{Port}}
\subsubsection[{peer}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ const {\bf Peer}$<$ A $>$ $\ast$ {\bf Port}$<$ A $>$::peer (
\begin{DoxyParamCaption}
\item[{const Addr \&}]{addr}
\end{DoxyParamCaption}
) const}}
\label{classPort_ad5a17f795e92df2fa8121449feb41cd9}


Get \hyperlink{classPeer}{Peer} identified by address. 

\begin{DoxyReturn}{Returns}
pointer to \hyperlink{classPeer}{Peer} on success, 0 otherwise. 
\end{DoxyReturn}
\hypertarget{classPort_ae2d4343154a778a8480f45119f302359}{
\index{Port@{Port}!peer\_\-gc\_\-timeout@{peer\_\-gc\_\-timeout}}
\index{peer\_\-gc\_\-timeout@{peer\_\-gc\_\-timeout}!Port@{Port}}
\subsubsection[{peer\_\-gc\_\-timeout}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ bool {\bf Port}$<$ A $>$::peer\_\-gc\_\-timeout (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_ae2d4343154a778a8480f45119f302359}


Poll peers and remove those with no routes. 

return true if peers still exist, false otherwise. \hypertarget{classPort_a8d210c0bbc179ce6ec83878cc097b800}{
\index{Port@{Port}!peers@{peers}}
\index{peers@{peers}!Port@{Port}}
\subsubsection[{peers}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ PeerList\& {\bf Port}$<$ A $>$::peers (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_a8d210c0bbc179ce6ec83878cc097b800}


Get Peers associated with this \hyperlink{classPort}{Port}. 

NB This method is a backdoor for testing purposes and should not be relied upon to exist in future. \hypertarget{classPort_a00f21335334571c30ac140273cd2f987}{
\index{Port@{Port}!port\_\-io\_\-enabled\_\-change@{port\_\-io\_\-enabled\_\-change}}
\index{port\_\-io\_\-enabled\_\-change@{port\_\-io\_\-enabled\_\-change}!Port@{Port}}
\subsubsection[{port\_\-io\_\-enabled\_\-change}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::port\_\-io\_\-enabled\_\-change (
\begin{DoxyParamCaption}
\item[{bool}]{en}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}virtual\mbox{]}}}}
\label{classPort_a00f21335334571c30ac140273cd2f987}


Notification that PortIO enabled state has changed. 

Called by PortIO when it's enabled status changes.


\begin{DoxyParams}{Parameters}
{\em en} & \hyperlink{protocolthe-p}{the} enabled status of \hyperlink{protocolthe-p}{the} I/O system. \\
\hline
\end{DoxyParams}


Implements \hyperlink{classPortIOUserBase}{PortIOUserBase$<$ A $>$}.

\hypertarget{classPort_adcb68aa0c998aac760271de1843655ee}{
\index{Port@{Port}!port\_\-io\_\-receive@{port\_\-io\_\-receive}}
\index{port\_\-io\_\-receive@{port\_\-io\_\-receive}!Port@{Port}}
\subsubsection[{port\_\-io\_\-receive}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::port\_\-io\_\-receive (
\begin{DoxyParamCaption}
\item[{const Addr \&}]{src\_\-addr, }
\item[{uint16\_\-t}]{src\_\-port, }
\item[{const uint8\_\-t $\ast$}]{rip\_\-packet, }
\item[{const size\_\-t}]{rip\_\-packet\_\-bytes}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}virtual\mbox{]}}}}
\label{classPort_adcb68aa0c998aac760271de1843655ee}


Receive RIP packet. 

Called by PortIO instance when a RIP packet arrives.


\begin{DoxyParams}{Parameters}
{\em addr} & source address of packet. \\
\hline
{\em port} & source port of packet. \\
\hline
{\em rip\_\-packet} & pointer to RIP packet data. \\
\hline
{\em rip\_\-packet\_\-bytes} & size of RIP packet data. \\
\hline
\end{DoxyParams}


Implements \hyperlink{classPortIOUserBase}{PortIOUserBase$<$ A $>$}.

\hypertarget{classPort_ae2b942d2a3d6fe5aad736f9551b5c6cb}{
\index{Port@{Port}!port\_\-io\_\-send\_\-completion@{port\_\-io\_\-send\_\-completion}}
\index{port\_\-io\_\-send\_\-completion@{port\_\-io\_\-send\_\-completion}!Port@{Port}}
\subsubsection[{port\_\-io\_\-send\_\-completion}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::port\_\-io\_\-send\_\-completion (
\begin{DoxyParamCaption}
\item[{bool}]{success}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}virtual\mbox{]}}}}
\label{classPort_ae2b942d2a3d6fe5aad736f9551b5c6cb}


\hyperlink{structSend}{Send} completion notification. 

Called by PortIO instance when a send request is completed.


\begin{DoxyParams}{Parameters}
{\em success} & indication of whether send completed successfully. \\
\hline
\end{DoxyParams}


Implements \hyperlink{classPortIOUserBase}{PortIOUserBase$<$ A $>$}.

\hypertarget{classPort_a655cbc2caa0ac81021dbba3a089552bf}{
\index{Port@{Port}!record\_\-bad\_\-packet@{record\_\-bad\_\-packet}}
\index{record\_\-bad\_\-packet@{record\_\-bad\_\-packet}!Port@{Port}}
\subsubsection[{record\_\-bad\_\-packet}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::record\_\-bad\_\-packet (
\begin{DoxyParamCaption}
\item[{const string \&}]{why, }
\item[{const Addr \&}]{addr, }
\item[{uint16\_\-t}]{port, }
\item[{{\bf Peer}$<$ A $>$ $\ast$}]{p}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_a655cbc2caa0ac81021dbba3a089552bf}


Record bad packet. 


\begin{DoxyParams}{Parameters}
{\em why} & reason packet marked \\
\hline
\end{DoxyParams}
\hypertarget{classPort_a8ed1ad92bd3dfed46720f0cde00a2e5a}{
\index{Port@{Port}!record\_\-bad\_\-route@{record\_\-bad\_\-route}}
\index{record\_\-bad\_\-route@{record\_\-bad\_\-route}!Port@{Port}}
\subsubsection[{record\_\-bad\_\-route}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::record\_\-bad\_\-route (
\begin{DoxyParamCaption}
\item[{const string \&}]{why, }
\item[{const Addr \&}]{src, }
\item[{uint16\_\-t}]{port, }
\item[{{\bf Peer}$<$ A $>$ $\ast$}]{p}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_a8ed1ad92bd3dfed46720f0cde00a2e5a}


Record bad route. 


\begin{DoxyParams}{Parameters}
{\em why} & reason packet marked \\
\hline
\end{DoxyParams}
\hypertarget{classPort_ac606fe7aac88bcc3f1a634c76a2af419}{
\index{Port@{Port}!record\_\-packet@{record\_\-packet}}
\index{record\_\-packet@{record\_\-packet}!Port@{Port}}
\subsubsection[{record\_\-packet}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::record\_\-packet (
\begin{DoxyParamCaption}
\item[{{\bf Peer}$<$ A $>$ $\ast$}]{p}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_ac606fe7aac88bcc3f1a634c76a2af419}


Record packet arrival. 

Updates port and peer counters. \hypertarget{classPort_a83704b041678e22740e437db2242649e}{
\index{Port@{Port}!request\_\-table@{request\_\-table}}
\index{request\_\-table@{request\_\-table}!Port@{Port}}
\subsubsection[{request\_\-table}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ bool {\bf Port}$<$ A $>$::request\_\-table (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_a83704b041678e22740e437db2242649e}


\hyperlink{structSend}{Send} request packet. 

\begin{DoxyReturn}{Returns}
true if packet sent, false if no packet sent. 
\end{DoxyReturn}
\hypertarget{classPort_aee9490742952d2277cf69e537ffd1f8d}{
\index{Port@{Port}!request\_\-table\_\-timeout@{request\_\-table\_\-timeout}}
\index{request\_\-table\_\-timeout@{request\_\-table\_\-timeout}!Port@{Port}}
\subsubsection[{request\_\-table\_\-timeout}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ bool {\bf Port}$<$ A $>$::request\_\-table\_\-timeout (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_aee9490742952d2277cf69e537ffd1f8d}


\hyperlink{structSend}{Send} request packet if there are no peers. 

\begin{DoxyReturn}{Returns}
true if packet sent, false if no packet sent. 
\end{DoxyReturn}
\hypertarget{classPort_a84df0a0dd7ed237b0708328a2d6d7d86}{
\index{Port@{Port}!reschedule\_\-request\_\-table\_\-timer@{reschedule\_\-request\_\-table\_\-timer}}
\index{reschedule\_\-request\_\-table\_\-timer@{reschedule\_\-request\_\-table\_\-timer}!Port@{Port}}
\subsubsection[{reschedule\_\-request\_\-table\_\-timer}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::reschedule\_\-request\_\-table\_\-timer (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classPort_a84df0a0dd7ed237b0708328a2d6d7d86}


Reschedule request table timer. 

If \hyperlink{protocolthe-p}{the} timer was not running, then don't schedule it. \hypertarget{classPort_adfa2be5f29a7754e950c2283b6ce45d4}{
\index{Port@{Port}!route\_\-policy@{route\_\-policy}}
\index{route\_\-policy@{route\_\-policy}!Port@{Port}}
\subsubsection[{route\_\-policy}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ pair$<$ A, uint16\_\-t $>$ {\bf Port}$<$ A $>$::route\_\-policy (
\begin{DoxyParamCaption}
\item[{const {\bf RouteEntry}$<$ A $>$ \&}]{re}
\end{DoxyParamCaption}
) const}}
\label{classPort_adfa2be5f29a7754e950c2283b6ce45d4}


Check policy on route. 

\begin{DoxyReturn}{Returns}
tuple (nexthop,cost). If route should not be advertised \hyperlink{protocolthe-p}{the} cost value will be greater than RIP\_\-INFINITY. 
\end{DoxyReturn}
\hypertarget{classPort_a1e2e7fcd8074166f36cc5ba09b20932c}{
\index{Port@{Port}!set\_\-accept\_\-default\_\-route@{set\_\-accept\_\-default\_\-route}}
\index{set\_\-accept\_\-default\_\-route@{set\_\-accept\_\-default\_\-route}!Port@{Port}}
\subsubsection[{set\_\-accept\_\-default\_\-route}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::set\_\-accept\_\-default\_\-route (
\begin{DoxyParamCaption}
\item[{bool}]{en}
\end{DoxyParamCaption}
)}}
\label{classPort_a1e2e7fcd8074166f36cc5ba09b20932c}


\hyperlink{classAccept}{Accept} default route if found in RIP response messages. 


\begin{DoxyParams}{Parameters}
{\em en} & true if default route should be accepted. \\
\hline
\end{DoxyParams}
\hypertarget{classPort_afaef9a5a602948031236205b244f0a0e}{
\index{Port@{Port}!set\_\-accept\_\-non\_\-rip\_\-requests@{set\_\-accept\_\-non\_\-rip\_\-requests}}
\index{set\_\-accept\_\-non\_\-rip\_\-requests@{set\_\-accept\_\-non\_\-rip\_\-requests}!Port@{Port}}
\subsubsection[{set\_\-accept\_\-non\_\-rip\_\-requests}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::set\_\-accept\_\-non\_\-rip\_\-requests (
\begin{DoxyParamCaption}
\item[{bool}]{en}
\end{DoxyParamCaption}
)}}
\label{classPort_afaef9a5a602948031236205b244f0a0e}


\hyperlink{classAccept}{Accept} and respond to non-\/RIP requests. 

Testing and Debugging tools typically send requests from non-\/RIP IP ports. \hypertarget{classPort_a1a349a66b05f5667f8d11fadef5956af}{
\index{Port@{Port}!set\_\-advertise@{set\_\-advertise}}
\index{set\_\-advertise@{set\_\-advertise}!Port@{Port}}
\subsubsection[{set\_\-advertise}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ void {\bf Port}$<$ A $>$::set\_\-advertise (
\begin{DoxyParamCaption}
\item[{bool}]{en}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_a1a349a66b05f5667f8d11fadef5956af}


Set \hyperlink{classPort}{Port} advertisement status. 


\begin{DoxyParams}{Parameters}
{\em en} & true if port should be advertised, false otherwise. \\
\hline
\end{DoxyParams}
\hypertarget{classPort_aea1a83309c849638061fad88482d20e7}{
\index{Port@{Port}!set\_\-advertise\_\-default\_\-route@{set\_\-advertise\_\-default\_\-route}}
\index{set\_\-advertise\_\-default\_\-route@{set\_\-advertise\_\-default\_\-route}!Port@{Port}}
\subsubsection[{set\_\-advertise\_\-default\_\-route}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::set\_\-advertise\_\-default\_\-route (
\begin{DoxyParamCaption}
\item[{bool}]{en}
\end{DoxyParamCaption}
)}}
\label{classPort_aea1a83309c849638061fad88482d20e7}


Configure whether default route is advertised in RIP response messages. 


\begin{DoxyParams}{Parameters}
{\em en} & true if default route should be advertised. \\
\hline
\end{DoxyParams}
\hypertarget{classPort_a1478db3be319e6c01da61582f5e83b62}{
\index{Port@{Port}!set\_\-enabled@{set\_\-enabled}}
\index{set\_\-enabled@{set\_\-enabled}!Port@{Port}}
\subsubsection[{set\_\-enabled}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::set\_\-enabled (
\begin{DoxyParamCaption}
\item[{bool}]{en}
\end{DoxyParamCaption}
)}}
\label{classPort_a1478db3be319e6c01da61582f5e83b62}


Set enabled state. 

When a port is enabled it can perform input and output processing. When not enabled, input data is discarded and output processing can not occur. \hypertarget{classPort_aee86d7ffc7f25050b6e7a40731779345}{
\index{Port@{Port}!set\_\-horizon@{set\_\-horizon}}
\index{set\_\-horizon@{set\_\-horizon}!Port@{Port}}
\subsubsection[{set\_\-horizon}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A$>$ void {\bf Port}$<$ A $>$::set\_\-horizon (
\begin{DoxyParamCaption}
\item[{const RipHorizon \&}]{h}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classPort_aee86d7ffc7f25050b6e7a40731779345}


Set horizon type associated with \hyperlink{classPort}{Port}. 


\begin{DoxyParams}{Parameters}
{\em h} & horizon type. \\
\hline
\end{DoxyParams}
\hypertarget{classPort_a51bd1b871d74b61a0ba8cca18263a2bc}{
\index{Port@{Port}!set\_\-passive@{set\_\-passive}}
\index{set\_\-passive@{set\_\-passive}!Port@{Port}}
\subsubsection[{set\_\-passive}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::set\_\-passive (
\begin{DoxyParamCaption}
\item[{bool}]{passive}
\end{DoxyParamCaption}
)}}
\label{classPort_a51bd1b871d74b61a0ba8cca18263a2bc}


\hyperlink{classAccept}{Accept} routes, but do not advertise them. 


\begin{DoxyParams}{Parameters}
{\em passive} & true if port should receive and not send packets. \\
\hline
\end{DoxyParams}
\hypertarget{classPort_aefa4c970dac0377c992785804e5ef5b6}{
\index{Port@{Port}!start\_\-output\_\-processing@{start\_\-output\_\-processing}}
\index{start\_\-output\_\-processing@{start\_\-output\_\-processing}!Port@{Port}}
\subsubsection[{start\_\-output\_\-processing}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::start\_\-output\_\-processing (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_aefa4c970dac0377c992785804e5ef5b6}


Start output processing. 

Starts timers for unsolicited updates and triggered updates. \hypertarget{classPort_a17315c546806fc71f2fab53a24b556ec}{
\index{Port@{Port}!start\_\-peer\_\-gc\_\-timer@{start\_\-peer\_\-gc\_\-timer}}
\index{start\_\-peer\_\-gc\_\-timer@{start\_\-peer\_\-gc\_\-timer}!Port@{Port}}
\subsubsection[{start\_\-peer\_\-gc\_\-timer}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::start\_\-peer\_\-gc\_\-timer (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_a17315c546806fc71f2fab53a24b556ec}


Start periodic timer to garbage collect peers. 

Timer deschedules itself when no peers exist. \hypertarget{classPort_a6314ca57c8b6082d35bc2ae8a10f325c}{
\index{Port@{Port}!start\_\-request\_\-table\_\-timer@{start\_\-request\_\-table\_\-timer}}
\index{start\_\-request\_\-table\_\-timer@{start\_\-request\_\-table\_\-timer}!Port@{Port}}
\subsubsection[{start\_\-request\_\-table\_\-timer}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::start\_\-request\_\-table\_\-timer (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_a6314ca57c8b6082d35bc2ae8a10f325c}


Start request table timer. 

When there are no peers, this schedules \hyperlink{protocolthe-p}{the} periodic transmission of request table packets. \hypertarget{classPort_aae39907270f2b10e3ff5e99f48e9e819}{
\index{Port@{Port}!stop\_\-output\_\-processing@{stop\_\-output\_\-processing}}
\index{stop\_\-output\_\-processing@{stop\_\-output\_\-processing}!Port@{Port}}
\subsubsection[{stop\_\-output\_\-processing}]{\setlength{\rightskip}{0pt plus 5cm}template$<$typename A $>$ void {\bf Port}$<$ A $>$::stop\_\-output\_\-processing (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{classPort_aae39907270f2b10e3ff5e99f48e9e819}


Stop output processing. 

Stops timers for unsolicited updates and triggered updates. 

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