\hypertarget{classIntraAreaPrefixLsa}{
\section{IntraAreaPrefixLsa Class Reference}
\label{classIntraAreaPrefixLsa}\index{IntraAreaPrefixLsa@{IntraAreaPrefixLsa}}
}


OSPFv3 only: Intra-\/Area-\/Prefix-\/LSA.  




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

Inheritance diagram for IntraAreaPrefixLsa:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=2.000000cm]{classIntraAreaPrefixLsa}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classIntraAreaPrefixLsa_a9430be4bd47e9cb097bc998ee34de5bd}{
{\bfseries IntraAreaPrefixLsa} (\hyperlink{structOspfTypes_a60eb031df0c10af753789ae76b185ec2}{OspfTypes::Version} version)}
\label{classIntraAreaPrefixLsa_a9430be4bd47e9cb097bc998ee34de5bd}

\item 
\hypertarget{classIntraAreaPrefixLsa_a64924433026a6db1d2df5b5cec69e5ba}{
{\bfseries IntraAreaPrefixLsa} (\hyperlink{structOspfTypes_a60eb031df0c10af753789ae76b185ec2}{OspfTypes::Version} version, uint8\_\-t $\ast$buf, size\_\-t len)}
\label{classIntraAreaPrefixLsa_a64924433026a6db1d2df5b5cec69e5ba}

\item 
size\_\-t \hyperlink{classIntraAreaPrefixLsa_af74c506d0064cd33b92fedbea0dd9d5a}{min\_\-length} () const 
\item 
uint16\_\-t \hyperlink{classIntraAreaPrefixLsa_a628c5595cb7bac08a49fc76b23dc7ccb}{get\_\-ls\_\-type} () const 
\begin{DoxyCompactList}\small\item\em It is \hyperlink{protocolthe-p}{the} responsibilty of \hyperlink{protocolthe-p}{the} derived type to return this information. \item\end{DoxyCompactList}\item 
\hyperlink{classref__ptr}{LsaRef} \hyperlink{classIntraAreaPrefixLsa_ac630470617bd664b1a68dcb2c6c622c2}{decode} (uint8\_\-t $\ast$buf, size\_\-t \&len) const   throw (InvalidPacket)
\begin{DoxyCompactList}\small\item\em Decode an LSA. \item\end{DoxyCompactList}\item 
bool \hyperlink{classIntraAreaPrefixLsa_a13a8312f7140494927554e1309df614c}{encode} ()
\begin{DoxyCompactList}\small\item\em Encode an LSA for transmission. \item\end{DoxyCompactList}\item 
\hypertarget{classIntraAreaPrefixLsa_a93cd24a6e297556f6785f19b50fdaea2}{
void {\bfseries set\_\-referenced\_\-ls\_\-type} (uint16\_\-t referenced\_\-ls\_\-type)}
\label{classIntraAreaPrefixLsa_a93cd24a6e297556f6785f19b50fdaea2}

\item 
\hypertarget{classIntraAreaPrefixLsa_a9311b316c3eb8ac314a12f584968f35c}{
uint16\_\-t {\bfseries get\_\-referenced\_\-ls\_\-type} () const }
\label{classIntraAreaPrefixLsa_a9311b316c3eb8ac314a12f584968f35c}

\item 
\hypertarget{classIntraAreaPrefixLsa_ac59cd0e62b8aa51b390121b65ef916cb}{
void {\bfseries set\_\-referenced\_\-link\_\-state\_\-id} (uint32\_\-t referenced\_\-link\_\-state\_\-id)}
\label{classIntraAreaPrefixLsa_ac59cd0e62b8aa51b390121b65ef916cb}

\item 
\hypertarget{classIntraAreaPrefixLsa_a0019869f9f0c6f968c7ea0b8d806dec0}{
uint32\_\-t {\bfseries get\_\-referenced\_\-link\_\-state\_\-id} () const }
\label{classIntraAreaPrefixLsa_a0019869f9f0c6f968c7ea0b8d806dec0}

\item 
\hypertarget{classIntraAreaPrefixLsa_ac7e04319c0416af79c4c5e6ce89d689a}{
void {\bfseries set\_\-referenced\_\-advertising\_\-router} (uint32\_\-t referenced\_\-adv\_\-router)}
\label{classIntraAreaPrefixLsa_ac7e04319c0416af79c4c5e6ce89d689a}

\item 
\hypertarget{classIntraAreaPrefixLsa_a3bbe6a147cc80c312517c3b8f820b507}{
uint32\_\-t {\bfseries get\_\-referenced\_\-advertising\_\-router} () const }
\label{classIntraAreaPrefixLsa_a3bbe6a147cc80c312517c3b8f820b507}

\item 
\hypertarget{classIntraAreaPrefixLsa_a3d3d1c71dc87e82f67e545246d58e46f}{
list$<$ \hyperlink{classIPv6Prefix}{IPv6Prefix} $>$ \& {\bfseries get\_\-prefixes} ()}
\label{classIntraAreaPrefixLsa_a3d3d1c71dc87e82f67e545246d58e46f}

\item 
uint32\_\-t \hyperlink{classIntraAreaPrefixLsa_ad0828869d629535a34af96271c6f81d8}{create\_\-link\_\-state\_\-id} (uint16\_\-t ls\_\-type, uint32\_\-t interface\_\-id) const 
\begin{DoxyCompactList}\small\item\em Given a referenced LS type and an interface ID generate a candidate Link State ID for Intra-\/Area-\/Prefix-\/LSAs. \item\end{DoxyCompactList}\item 
\hypertarget{classIntraAreaPrefixLsa_af2ee65d48f99ab7ca520417e874a79a0}{
const char $\ast$ \hyperlink{classIntraAreaPrefixLsa_af2ee65d48f99ab7ca520417e874a79a0}{name} () const }
\label{classIntraAreaPrefixLsa_af2ee65d48f99ab7ca520417e874a79a0}

\begin{DoxyCompactList}\small\item\em Printable name of this LSA. \item\end{DoxyCompactList}\item 
\hypertarget{classIntraAreaPrefixLsa_a5dc7c0bd9beecd19e2712dd7d4e3d995}{
string \hyperlink{classIntraAreaPrefixLsa_a5dc7c0bd9beecd19e2712dd7d4e3d995}{str} () const }
\label{classIntraAreaPrefixLsa_a5dc7c0bd9beecd19e2712dd7d4e3d995}

\begin{DoxyCompactList}\small\item\em Generate a printable representation. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classIntraAreaPrefixLsa_ac6b55b7676d32e5444c30ccf2df16db8}{
uint16\_\-t {\bfseries \_\-referenced\_\-ls\_\-type}}
\label{classIntraAreaPrefixLsa_ac6b55b7676d32e5444c30ccf2df16db8}

\item 
\hypertarget{classIntraAreaPrefixLsa_a2d5c563f1bda977548018f6bbeaf9d61}{
uint32\_\-t {\bfseries \_\-referenced\_\-link\_\-state\_\-id}}
\label{classIntraAreaPrefixLsa_a2d5c563f1bda977548018f6bbeaf9d61}

\item 
\hypertarget{classIntraAreaPrefixLsa_a192180a52e8fca9f38db2ab70a086eb5}{
uint32\_\-t {\bfseries \_\-referenced\_\-advertising\_\-router}}
\label{classIntraAreaPrefixLsa_a192180a52e8fca9f38db2ab70a086eb5}

\item 
\hypertarget{classIntraAreaPrefixLsa_ad9c910353d9fb5926279533bb7f2a353}{
list$<$ \hyperlink{classIPv6Prefix}{IPv6Prefix} $>$ {\bfseries \_\-prefixes}}
\label{classIntraAreaPrefixLsa_ad9c910353d9fb5926279533bb7f2a353}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
OSPFv3 only: Intra-\/Area-\/Prefix-\/LSA. 

\subsection{Member Function Documentation}
\hypertarget{classIntraAreaPrefixLsa_ad0828869d629535a34af96271c6f81d8}{
\index{IntraAreaPrefixLsa@{IntraAreaPrefixLsa}!create\_\-link\_\-state\_\-id@{create\_\-link\_\-state\_\-id}}
\index{create\_\-link\_\-state\_\-id@{create\_\-link\_\-state\_\-id}!IntraAreaPrefixLsa@{IntraAreaPrefixLsa}}
\subsubsection[{create\_\-link\_\-state\_\-id}]{\setlength{\rightskip}{0pt plus 5cm}uint32\_\-t IntraAreaPrefixLsa::create\_\-link\_\-state\_\-id (
\begin{DoxyParamCaption}
\item[{uint16\_\-t}]{ls\_\-type, }
\item[{uint32\_\-t}]{interface\_\-id}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classIntraAreaPrefixLsa_ad0828869d629535a34af96271c6f81d8}


Given a referenced LS type and an interface ID generate a candidate Link State ID for Intra-\/Area-\/Prefix-\/LSAs. 

This is $\ast$NOT$\ast$ part of \hyperlink{protocolthe-p}{the} protocol, just a way to create a unique mapping.

The underlying assumption is that for every area only one Intra-\/Area-\/Prefix-\/LSA will be generated per Router-\/LSA and Network-\/LSA. More importantly one Router-\/LSA will be generated per area although it is legal to generate many. The size of \hyperlink{protocolthe-p}{the} Router-\/LSA is a function of \hyperlink{protocolthe-p}{the} number of interfaces on \hyperlink{protocolthe-p}{the} generating router and for \hyperlink{protocolthe-p}{the} time being we only generate one Router-\/LSA. If \hyperlink{protocolthe-p}{the} number of interfaces exceeds \hyperlink{protocolthe-p}{the} capacity of a single Router-\/LSA then this method and \hyperlink{protocolthe-p}{the} Router-\/LSA code will need to be re-\/visited. \hypertarget{classIntraAreaPrefixLsa_ac630470617bd664b1a68dcb2c6c622c2}{
\index{IntraAreaPrefixLsa@{IntraAreaPrefixLsa}!decode@{decode}}
\index{decode@{decode}!IntraAreaPrefixLsa@{IntraAreaPrefixLsa}}
\subsubsection[{decode}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Lsa::LsaRef} IntraAreaPrefixLsa::decode (
\begin{DoxyParamCaption}
\item[{uint8\_\-t $\ast$}]{buf, }
\item[{size\_\-t \&}]{len}
\end{DoxyParamCaption}
) const  throw ({\bf InvalidPacket})\hspace{0.3cm}{\ttfamily  \mbox{[}virtual\mbox{]}}}}
\label{classIntraAreaPrefixLsa_ac630470617bd664b1a68dcb2c6c622c2}


Decode an LSA. 


\begin{DoxyParams}{Parameters}
{\em buf} & pointer to buffer. \\
\hline
{\em len} & length of \hyperlink{protocolthe-p}{the} buffer on input set to \hyperlink{protocolthe-p}{the} number of bytes consumed on output.\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A reference to an LSA that manages its own memory. 
\end{DoxyReturn}


Implements \hyperlink{classLsa_a2658a7d54d470268138d15938be0f464}{Lsa}.

\hypertarget{classIntraAreaPrefixLsa_a13a8312f7140494927554e1309df614c}{
\index{IntraAreaPrefixLsa@{IntraAreaPrefixLsa}!encode@{encode}}
\index{encode@{encode}!IntraAreaPrefixLsa@{IntraAreaPrefixLsa}}
\subsubsection[{encode}]{\setlength{\rightskip}{0pt plus 5cm}bool IntraAreaPrefixLsa::encode (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}virtual\mbox{]}}}}
\label{classIntraAreaPrefixLsa_a13a8312f7140494927554e1309df614c}


Encode an LSA for transmission. 

\begin{DoxyReturn}{Returns}
True on success. 
\end{DoxyReturn}


Implements \hyperlink{classLsa_ae3bd3a0bd24ed458cc8ac8d7e91d1c35}{Lsa}.

\hypertarget{classIntraAreaPrefixLsa_a628c5595cb7bac08a49fc76b23dc7ccb}{
\index{IntraAreaPrefixLsa@{IntraAreaPrefixLsa}!get\_\-ls\_\-type@{get\_\-ls\_\-type}}
\index{get\_\-ls\_\-type@{get\_\-ls\_\-type}!IntraAreaPrefixLsa@{IntraAreaPrefixLsa}}
\subsubsection[{get\_\-ls\_\-type}]{\setlength{\rightskip}{0pt plus 5cm}uint16\_\-t IntraAreaPrefixLsa::get\_\-ls\_\-type (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline, virtual\mbox{]}}}}
\label{classIntraAreaPrefixLsa_a628c5595cb7bac08a49fc76b23dc7ccb}


It is \hyperlink{protocolthe-p}{the} responsibilty of \hyperlink{protocolthe-p}{the} derived type to return this information. 

\begin{DoxyReturn}{Returns}
The type this lsa represents. 
\end{DoxyReturn}


Implements \hyperlink{classLsa_a0dcc648678ac88856635609a17029ae9}{Lsa}.

\hypertarget{classIntraAreaPrefixLsa_af74c506d0064cd33b92fedbea0dd9d5a}{
\index{IntraAreaPrefixLsa@{IntraAreaPrefixLsa}!min\_\-length@{min\_\-length}}
\index{min\_\-length@{min\_\-length}!IntraAreaPrefixLsa@{IntraAreaPrefixLsa}}
\subsubsection[{min\_\-length}]{\setlength{\rightskip}{0pt plus 5cm}size\_\-t IntraAreaPrefixLsa::min\_\-length (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline, virtual\mbox{]}}}}
\label{classIntraAreaPrefixLsa_af74c506d0064cd33b92fedbea0dd9d5a}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} minimum length of a Link-\/LSA. 
\end{DoxyReturn}


Implements \hyperlink{classLsa_ad3324ea3bfa81ff90d15690c5ccbd1e4}{Lsa}.



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