\hypertarget{classCliNode}{
\section{CliNode Class Reference}
\label{classCliNode}\index{CliNode@{CliNode}}
}


The class for \hyperlink{protocolthe-p}{the} CLI node.  




{\ttfamily \#include $<$cli\_\-node.hh$>$}

Inheritance diagram for CliNode:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=6.000000cm]{classCliNode}
\end{center}
\end{figure}
\subsection*{Public Types}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classCliNode_ab74fdda82d730c764386e9c0ee736fd3}{
typedef XorpCallback6$<$ void, const string \&, const string \&, const string \&, uint32\_\-t, const vector$<$ string $>$ \&, const vector$<$ string $>$ \& $>$::RefPtr {\bfseries SenderProcessCallback}}
\label{classCliNode_ab74fdda82d730c764386e9c0ee736fd3}

\item 
\hypertarget{classCliNode_a2df2067f8678945c3ce291cd7c1c6635}{
typedef XorpCallback1$<$ void, \hyperlink{classCliClient}{CliClient} $\ast$ $>$::RefPtr {\bfseries CliClientDeleteCallback}}
\label{classCliNode_a2df2067f8678945c3ce291cd7c1c6635}

\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{classCliNode_abc7f4824ab395d990270ca5743f53e2a}{CliNode} (int init\_\-family, xorp\_\-module\_\-id init\_\-module\_\-id, \hyperlink{classEventLoop}{EventLoop} \&init\_\-eventloop)
\begin{DoxyCompactList}\small\item\em Constructor for a given address family, module ID, and event loop. \item\end{DoxyCompactList}\item 
virtual \hyperlink{classCliNode_a3a6422c06732684cbafc62c5d3e3bdd2}{$\sim$CliNode} ()
\begin{DoxyCompactList}\small\item\em Destructor. \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_acfe69d3c37b7fd6ee5fc60cd04693fbc}{start} ()
\begin{DoxyCompactList}\small\item\em Start \hyperlink{protocolthe-p}{the} node operation. \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_a48ea54e6748aad1de1716ed157d95106}{stop} ()
\begin{DoxyCompactList}\small\item\em Stop \hyperlink{protocolthe-p}{the} node operation. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_a8f260c6eaf7369bc30281600a24aa1aa}{enable} ()
\begin{DoxyCompactList}\small\item\em Enable node operation. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_af5805d18583ba6ea5422144b009081ba}{disable} ()
\begin{DoxyCompactList}\small\item\em Disable node operation. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_aa45b8d4f270533aa740bcfb4ec6c2869}{set\_\-cli\_\-port} (unsigned short v)
\begin{DoxyCompactList}\small\item\em Set \hyperlink{protocolthe-p}{the} CLI access port. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_ae216cb28dfbc044560c173a83948490a}{add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet} (const \hyperlink{classIPvXNet}{IPvXNet} \&subnet\_\-addr)
\begin{DoxyCompactList}\small\item\em Add a subnet address to \hyperlink{protocolthe-p}{the} list of subnet addresses enabled for CLI access. \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_af03427426adf491b17353adb9191aad6}{delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet} (const \hyperlink{classIPvXNet}{IPvXNet} \&subnet\_\-addr)
\begin{DoxyCompactList}\small\item\em Delete a subnet address from \hyperlink{protocolthe-p}{the} list of subnet addresses enabled for CLI access. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_a3de2e9b3d0574cac2035e19ae767c250}{add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet} (const \hyperlink{classIPvXNet}{IPvXNet} \&subnet\_\-addr)
\begin{DoxyCompactList}\small\item\em Add a subnet address to \hyperlink{protocolthe-p}{the} list of subnet addresses disabled for CLI access. \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_add71d03105e22bac894967b64eff8213}{delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet} (const \hyperlink{classIPvXNet}{IPvXNet} \&subnet\_\-addr)
\begin{DoxyCompactList}\small\item\em Delete a subnet address from \hyperlink{protocolthe-p}{the} list of subnet addresses disabled for CLI access. \item\end{DoxyCompactList}\item 
\hyperlink{classCliCommand}{CliCommand} $\ast$ \hyperlink{classCliNode_ac9db32d54a94c76809ce2d968ff0817f}{cli\_\-command\_\-root} ()
\begin{DoxyCompactList}\small\item\em Get \hyperlink{protocolthe-p}{the} \hyperlink{classCliCommand}{CliCommand} entry for \hyperlink{protocolthe-p}{the} CLI root command. \item\end{DoxyCompactList}\item 
\hyperlink{classCliClient}{CliClient} $\ast$ \hyperlink{classCliNode_a2295f07f5b4b9d82b98fa6fd5d3343ef}{find\_\-cli\_\-by\_\-term\_\-name} (const string \&term\_\-name) const 
\begin{DoxyCompactList}\small\item\em Find a CLI client \hyperlink{classCliClient}{CliClient} for a given terminal name. \item\end{DoxyCompactList}\item 
\hyperlink{classCliClient}{CliClient} $\ast$ \hyperlink{classCliNode_adf9061abc373387f3e3f55b69b361f94}{find\_\-cli\_\-by\_\-session\_\-id} (uint32\_\-t session\_\-id) const 
\begin{DoxyCompactList}\small\item\em Find a CLI client \hyperlink{classCliClient}{CliClient} for a given session ID. \item\end{DoxyCompactList}\item 
list$<$ \hyperlink{classCliClient}{CliClient} $\ast$ $>$ \& \hyperlink{classCliNode_a8a27be0d016c5b0e2090e78fa38cf199}{client\_\-list} ()
\begin{DoxyCompactList}\small\item\em Get \hyperlink{protocolthe-p}{the} list of CLI clients (see \hyperlink{classCliClient}{CliClient}). \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_a25789ac89e80c43b4ece84fef643dbd2}{add\_\-cli\_\-command} (const string \&processor\_\-name, const string \&command\_\-name, const string \&command\_\-help, const bool \&is\_\-command\_\-cd, const string \&command\_\-cd\_\-prompt, const bool \&is\_\-command\_\-processor, string \&error\_\-msg)
\begin{DoxyCompactList}\small\item\em Add a CLI command to \hyperlink{protocolthe-p}{the} CLI manager. \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_accc870d97a3a6463d671e9997969d496}{delete\_\-cli\_\-command} (const string \&processor\_\-name, const string \&command\_\-name, string \&error\_\-msg)
\begin{DoxyCompactList}\small\item\em Delete a CLI command from \hyperlink{protocolthe-p}{the} CLI manager. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_a8fd9de908796fb6bc0214e45f4d814fc}{recv\_\-process\_\-command\_\-output} (const string $\ast$processor\_\-name, const string $\ast$cli\_\-term\_\-name, const uint32\_\-t $\ast$cli\_\-session\_\-id, const string $\ast$command\_\-output)
\begin{DoxyCompactList}\small\item\em Process \hyperlink{protocolthe-p}{the} response of a command processed by a remote node. \item\end{DoxyCompactList}\item 
\hypertarget{classCliNode_a18c1ec32382ebc8848cf7de33e6f0d84}{
int \hyperlink{classCliNode_a18c1ec32382ebc8848cf7de33e6f0d84}{proto\_\-recv} (const string \&, const string \&, const \hyperlink{classIPvX}{IPvX} \&, const \hyperlink{classIPvX}{IPvX} \&, uint8\_\-t, int32\_\-t, int32\_\-t, bool, bool, const vector$<$ uint8\_\-t $>$ \&, string \&)}
\label{classCliNode_a18c1ec32382ebc8848cf7de33e6f0d84}

\begin{DoxyCompactList}\small\item\em UNUSED. \item\end{DoxyCompactList}\item 
\hypertarget{classCliNode_a62b1a6e455db8da87df6c865f0a0b126}{
int \hyperlink{classCliNode_a62b1a6e455db8da87df6c865f0a0b126}{proto\_\-send} (const string \&, const string \&, const \hyperlink{classIPvX}{IPvX} \&, const \hyperlink{classIPvX}{IPvX} \&, uint8\_\-t, int32\_\-t, int32\_\-t, bool, bool, const uint8\_\-t $\ast$, size\_\-t, string \&)}
\label{classCliNode_a62b1a6e455db8da87df6c865f0a0b126}

\begin{DoxyCompactList}\small\item\em UNUSED. \item\end{DoxyCompactList}\item 
\hypertarget{classCliNode_a34ddc5dd5aaf4fae22d0f46604f59b76}{
int \hyperlink{classCliNode_a34ddc5dd5aaf4fae22d0f46604f59b76}{signal\_\-message\_\-recv} (const string \&, int, uint32\_\-t, const \hyperlink{classIPvX}{IPvX} \&, const \hyperlink{classIPvX}{IPvX} \&, const uint8\_\-t $\ast$, size\_\-t)}
\label{classCliNode_a34ddc5dd5aaf4fae22d0f46604f59b76}

\begin{DoxyCompactList}\small\item\em UNUSED. \item\end{DoxyCompactList}\item 
\hypertarget{classCliNode_a5d822430c10e88bbb74f4bc208673237}{
int \hyperlink{classCliNode_a5d822430c10e88bbb74f4bc208673237}{signal\_\-message\_\-send} (const string \&, int, uint32\_\-t, const \hyperlink{classIPvX}{IPvX} \&, const \hyperlink{classIPvX}{IPvX} \&, const uint8\_\-t $\ast$, size\_\-t)}
\label{classCliNode_a5d822430c10e88bbb74f4bc208673237}

\begin{DoxyCompactList}\small\item\em UNUSED. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_aaf1faa816fe88d1dc595a10e8f257d66}{set\_\-send\_\-process\_\-command\_\-callback} (const SenderProcessCallback \&v)
\begin{DoxyCompactList}\small\item\em Set a callback to send a CLI command to a processing module. \item\end{DoxyCompactList}\item 
\hyperlink{classCliClient}{CliClient} $\ast$ \hyperlink{classCliNode_ab6ca2e8448368683d0f99965e2bda587}{add\_\-client} (\hyperlink{classXorpFd}{XorpFd} input\_\-fd, \hyperlink{classXorpFd}{XorpFd} output\_\-fd, bool is\_\-network, const string \&startup\_\-cli\_\-prompt, string \&error\_\-msg)
\begin{DoxyCompactList}\small\item\em Add a CLI client (\hyperlink{classCliClient}{CliClient}) to \hyperlink{protocolthe-p}{the} CLI with enabled access from a file descriptor. \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_aa7d68faaca271a02061c5922495e27c7}{remove\_\-client} (\hyperlink{classCliClient}{CliClient} $\ast$cli\_\-client, string \&error\_\-msg)
\begin{DoxyCompactList}\small\item\em Remove a CLI client (\hyperlink{classCliClient}{CliClient}) from \hyperlink{protocolthe-p}{the} CLI. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_ab192e1ad6a0eafded6175df9ddf86922}{set\_\-cli\_\-client\_\-delete\_\-callback} (const CliClientDeleteCallback \&v)
\begin{DoxyCompactList}\small\item\em Set \hyperlink{protocolthe-p}{the} callback method that is invoked whenever a \hyperlink{classCliClient}{CliClient} is deleted. \item\end{DoxyCompactList}\item 
bool \hyperlink{classCliNode_a435c77f502407cd977ddb4e45f8f6e5e}{is\_\-log\_\-trace} () const 
\begin{DoxyCompactList}\small\item\em Test if trace log is enabled. \item\end{DoxyCompactList}\item 
void \hyperlink{classCliNode_a2da662f867e234852f5bba1b24e2d5ec}{set\_\-log\_\-trace} (bool is\_\-enabled)
\begin{DoxyCompactList}\small\item\em Enable/disable trace log. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
static int \hyperlink{classCliNode_a3900062d57140d5c807d56b8c3c65471}{xlog\_\-output} (void $\ast$obj, xlog\_\-level\_\-t level, const char $\ast$msg)
\begin{DoxyCompactList}\small\item\em \hyperlink{classOutput}{Output} a log message to a \hyperlink{classCliClient}{CliClient} object. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Member Functions}
\begin{DoxyCompactItemize}
\item 
int \hyperlink{classCliNode_ab80706e4b958b6f2b45119a765702004}{add\_\-internal\_\-cli\_\-commands} (string \&error\_\-msg)
\begin{DoxyCompactList}\small\item\em \hyperlink{classCliNode_ab80706e4b958b6f2b45119a765702004}{CliNode::add\_\-internal\_\-cli\_\-commands}: : The error message (if error). \item\end{DoxyCompactList}\item 
\hypertarget{classCliNode_a498c7e046e2beb11c7e7bcf0bd0458f7}{
int {\bfseries cli\_\-show\_\-log} (const string \&server\_\-name, const string \&cli\_\-term\_\-name, uint32\_\-t cli\_\-session\_\-id, const vector$<$ string $>$ \&command\_\-global\_\-name, const vector$<$ string $>$ \&argv)}
\label{classCliNode_a498c7e046e2beb11c7e7bcf0bd0458f7}

\item 
\hypertarget{classCliNode_aa303d85dfb74fd6d75982221f46349dc}{
int {\bfseries cli\_\-show\_\-log\_\-user} (const string \&server\_\-name, const string \&cli\_\-term\_\-name, uint32\_\-t cli\_\-session\_\-id, const vector$<$ string $>$ \&command\_\-global\_\-name, const vector$<$ string $>$ \&argv)}
\label{classCliNode_aa303d85dfb74fd6d75982221f46349dc}

\item 
\hypertarget{classCliNode_ab908a887b1efa6185fa88258314caad2}{
int {\bfseries cli\_\-set\_\-log\_\-output\_\-cli} (const string \&server\_\-name, const string \&cli\_\-term\_\-name, uint32\_\-t cli\_\-session\_\-id, const vector$<$ string $>$ \&command\_\-global\_\-name, const vector$<$ string $>$ \&argv)}
\label{classCliNode_ab908a887b1efa6185fa88258314caad2}

\item 
\hypertarget{classCliNode_ae920cebe9a28ea8c65a91875512e6875}{
int {\bfseries cli\_\-set\_\-log\_\-output\_\-file} (const string \&server\_\-name, const string \&cli\_\-term\_\-name, uint32\_\-t cli\_\-session\_\-id, const vector$<$ string $>$ \&command\_\-global\_\-name, const vector$<$ string $>$ \&argv)}
\label{classCliNode_ae920cebe9a28ea8c65a91875512e6875}

\item 
\hypertarget{classCliNode_a74beb04f6a03f336e1cd7a05f49295a3}{
int {\bfseries cli\_\-set\_\-log\_\-output\_\-remove\_\-cli} (const string \&server\_\-name, const string \&cli\_\-term\_\-name, uint32\_\-t cli\_\-session\_\-id, const vector$<$ string $>$ \&command\_\-global\_\-name, const vector$<$ string $>$ \&argv)}
\label{classCliNode_a74beb04f6a03f336e1cd7a05f49295a3}

\item 
\hypertarget{classCliNode_af4e029ed3af0fb30d2c6faa9bb0a9c92}{
int {\bfseries cli\_\-set\_\-log\_\-output\_\-remove\_\-file} (const string \&server\_\-name, const string \&cli\_\-term\_\-name, uint32\_\-t cli\_\-session\_\-id, const vector$<$ string $>$ \&command\_\-global\_\-name, const vector$<$ string $>$ \&argv)}
\label{classCliNode_af4e029ed3af0fb30d2c6faa9bb0a9c92}

\item 
\hypertarget{classCliNode_a5f6e38bb1317e1eb685131574b80c90d}{
int {\bfseries send\_\-process\_\-command} (const string \&server\_\-name, const string \&cli\_\-term\_\-name, const uint32\_\-t cli\_\-session\_\-id, const vector$<$ string $>$ \&command\_\-global\_\-name, const vector$<$ string $>$ \&argv)}
\label{classCliNode_a5f6e38bb1317e1eb685131574b80c90d}

\item 
\hyperlink{classXorpFd}{XorpFd} \hyperlink{classCliNode_abd410a3ec9fe345def7fb96eb0451403}{sock\_\-serv\_\-open} ()
\begin{DoxyCompactList}\small\item\em \hyperlink{classCliNode_abd410a3ec9fe345def7fb96eb0451403}{CliNode::sock\_\-serv\_\-open}: \item\end{DoxyCompactList}\item 
int \hyperlink{classCliNode_a89d2da28f650829befe92a2cf10463c3}{sock\_\-serv\_\-close} ()
\begin{DoxyCompactList}\small\item\em \hyperlink{classCliNode_a89d2da28f650829befe92a2cf10463c3}{CliNode::sock\_\-serv\_\-close}: @: \item\end{DoxyCompactList}\item 
\hypertarget{classCliNode_ae0dcff8c70c0efa80461ccf8b389b0c5}{
\hyperlink{classCliClient}{CliClient} $\ast$ {\bfseries add\_\-connection} (\hyperlink{classXorpFd}{XorpFd} input\_\-fd, \hyperlink{classXorpFd}{XorpFd} output\_\-fd, bool is\_\-network, const string \&startup\_\-cli\_\-prompt, string \&error\_\-msg)}
\label{classCliNode_ae0dcff8c70c0efa80461ccf8b389b0c5}

\item 
\hypertarget{classCliNode_aa8cfe2746b556c0b5a202ab8a7554f09}{
int {\bfseries delete\_\-connection} (\hyperlink{classCliClient}{CliClient} $\ast$cli\_\-client, string \&error\_\-msg)}
\label{classCliNode_aa8cfe2746b556c0b5a202ab8a7554f09}

\item 
\hypertarget{classCliNode_ad9aec1559e107f86aa7d0bacaaad24f0}{
void {\bfseries accept\_\-connection} (\hyperlink{classXorpFd}{XorpFd} fd, IoEventType type)}
\label{classCliNode_ad9aec1559e107f86aa7d0bacaaad24f0}

\item 
\hypertarget{classCliNode_ad1898bd28c8b11be41f9c6745a49695f}{
bool {\bfseries is\_\-allow\_\-cli\_\-access} (const \hyperlink{classIPvX}{IPvX} \&ipvx) const }
\label{classCliNode_ad1898bd28c8b11be41f9c6745a49695f}

\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classCliNode_a284cce27221f317d1a168d504409842c}{
\hyperlink{classXorpFd}{XorpFd} {\bfseries \_\-cli\_\-socket}}
\label{classCliNode_a284cce27221f317d1a168d504409842c}

\item 
\hypertarget{classCliNode_a907f66cb57020611b3820aa49817c0f4}{
unsigned short {\bfseries \_\-cli\_\-port}}
\label{classCliNode_a907f66cb57020611b3820aa49817c0f4}

\item 
\hypertarget{classCliNode_aa77f03bea92ffd484d5825e5e688a772}{
list$<$ \hyperlink{classCliClient}{CliClient} $\ast$ $>$ {\bfseries \_\-client\_\-list}}
\label{classCliNode_aa77f03bea92ffd484d5825e5e688a772}

\item 
\hypertarget{classCliNode_aba514ffa7f07a2b9a6a929384e27d4d0}{
uint32\_\-t {\bfseries \_\-next\_\-session\_\-id}}
\label{classCliNode_aba514ffa7f07a2b9a6a929384e27d4d0}

\item 
\hypertarget{classCliNode_a22520c2977228e96c7757e3d11457e94}{
string {\bfseries \_\-startup\_\-cli\_\-prompt}}
\label{classCliNode_a22520c2977228e96c7757e3d11457e94}

\item 
\hypertarget{classCliNode_abc8b61c761ca160e4f3c1bd00e157c07}{
\hyperlink{classCliCommand}{CliCommand} {\bfseries \_\-cli\_\-command\_\-root}}
\label{classCliNode_abc8b61c761ca160e4f3c1bd00e157c07}

\item 
\hypertarget{classCliNode_a675edc8b044f2dcca3fc72ff41cae32f}{
SenderProcessCallback {\bfseries \_\-send\_\-process\_\-command\_\-callback}}
\label{classCliNode_a675edc8b044f2dcca3fc72ff41cae32f}

\item 
\hypertarget{classCliNode_a302f40092584d02dfd16180fc4e3f9fc}{
CliClientDeleteCallback {\bfseries \_\-cli\_\-client\_\-delete\_\-callback}}
\label{classCliNode_a302f40092584d02dfd16180fc4e3f9fc}

\item 
\hypertarget{classCliNode_adfc33cd43ad0832e51835ca538c733e4}{
list$<$ \hyperlink{classIPvXNet}{IPvXNet} $>$ {\bfseries \_\-enable\_\-cli\_\-access\_\-subnet\_\-list}}
\label{classCliNode_adfc33cd43ad0832e51835ca538c733e4}

\item 
\hypertarget{classCliNode_ac694ec26a7d1c45cf351d5a565e41cc9}{
list$<$ \hyperlink{classIPvXNet}{IPvXNet} $>$ {\bfseries \_\-disable\_\-cli\_\-access\_\-subnet\_\-list}}
\label{classCliNode_ac694ec26a7d1c45cf351d5a565e41cc9}

\item 
\hypertarget{classCliNode_a996dc09bb50f9ee552f9d968599a5b99}{
bool {\bfseries \_\-is\_\-log\_\-trace}}
\label{classCliNode_a996dc09bb50f9ee552f9d968599a5b99}

\end{DoxyCompactItemize}
\subsection*{Friends}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classCliNode_a45fce1503a9696bee70b932121b6a889}{
class \hyperlink{classCliNode_a45fce1503a9696bee70b932121b6a889}{CliClient}}
\label{classCliNode_a45fce1503a9696bee70b932121b6a889}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
The class for \hyperlink{protocolthe-p}{the} CLI node. There should one node per CLI instance. There should be one CLI instance per router. 

\subsection{Constructor \& Destructor Documentation}
\hypertarget{classCliNode_abc7f4824ab395d990270ca5743f53e2a}{
\index{CliNode@{CliNode}!CliNode@{CliNode}}
\index{CliNode@{CliNode}!CliNode@{CliNode}}
\subsubsection[{CliNode}]{\setlength{\rightskip}{0pt plus 5cm}CliNode::CliNode (
\begin{DoxyParamCaption}
\item[{int}]{init\_\-family, }
\item[{xorp\_\-module\_\-id}]{module\_\-id, }
\item[{{\bf EventLoop} \&}]{init\_\-eventloop}
\end{DoxyParamCaption}
)}}
\label{classCliNode_abc7f4824ab395d990270ca5743f53e2a}


Constructor for a given address family, module ID, and event loop. 

\hyperlink{classCliNode_abc7f4824ab395d990270ca5743f53e2a}{CliNode::CliNode}: : The address family (AF\_\-INET or AF\_\-INET6 for \hyperlink{classIPv4}{IPv4} and \hyperlink{classIPv6}{IPv6} respectively).


\begin{DoxyParams}{Parameters}
{\em init\_\-family} & \hyperlink{protocolthe-p}{the} address family (AF\_\-INET or AF\_\-INET6 for \hyperlink{classIPv4}{IPv4} and \hyperlink{classIPv6}{IPv6} respectively). Note that this argument may disappear in \hyperlink{protocolthe-p}{the} future, and a single Cli node would provide access for both \hyperlink{classIPv4}{IPv4} and \hyperlink{classIPv6}{IPv6}. \\
\hline
{\em init\_\-module\_\-id} & \hyperlink{protocolthe-p}{the} module ID (xorp\_\-module\_\-id). Should be equal to XORP\_\-MODULE\_\-CLI. \\
\hline
{\em init\_\-eventloop} & \hyperlink{protocolthe-p}{the} event loop to use.\\
\hline
\end{DoxyParams}
: The module ID (must be XORP\_\-MODULE\_\-CLI). : The event loop.

CLI node constructor. \hypertarget{classCliNode_a3a6422c06732684cbafc62c5d3e3bdd2}{
\index{CliNode@{CliNode}!$\sim$CliNode@{$\sim$CliNode}}
\index{$\sim$CliNode@{$\sim$CliNode}!CliNode@{CliNode}}
\subsubsection[{$\sim$CliNode}]{\setlength{\rightskip}{0pt plus 5cm}CliNode::$\sim$CliNode (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}virtual\mbox{]}}}}
\label{classCliNode_a3a6422c06732684cbafc62c5d3e3bdd2}


Destructor. 

\hyperlink{classCliNode_a3a6422c06732684cbafc62c5d3e3bdd2}{CliNode::$\sim$CliNode}: @:

CLI node destructor. 

\subsection{Member Function Documentation}
\hypertarget{classCliNode_a25789ac89e80c43b4ece84fef643dbd2}{
\index{CliNode@{CliNode}!add\_\-cli\_\-command@{add\_\-cli\_\-command}}
\index{add\_\-cli\_\-command@{add\_\-cli\_\-command}!CliNode@{CliNode}}
\subsubsection[{add\_\-cli\_\-command}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::add\_\-cli\_\-command (
\begin{DoxyParamCaption}
\item[{const string \&}]{processor\_\-name, }
\item[{const string \&}]{command\_\-name, }
\item[{const string \&}]{command\_\-help, }
\item[{const bool \&}]{is\_\-command\_\-cd, }
\item[{const string \&}]{command\_\-cd\_\-prompt, }
\item[{const bool \&}]{is\_\-command\_\-processor, }
\item[{string \&}]{error\_\-msg}
\end{DoxyParamCaption}
)}}
\label{classCliNode_a25789ac89e80c43b4ece84fef643dbd2}


Add a CLI command to \hyperlink{protocolthe-p}{the} CLI manager. 


\begin{DoxyParams}{Parameters}
{\em processor\_\-name} & \hyperlink{protocolthe-p}{the} name of \hyperlink{protocolthe-p}{the} module that will process that command. \\
\hline
{\em command\_\-name} & \hyperlink{protocolthe-p}{the} name of \hyperlink{protocolthe-p}{the} command to add. \\
\hline
{\em command\_\-help} & \hyperlink{protocolthe-p}{the} help for \hyperlink{protocolthe-p}{the} command to add. \\
\hline
{\em is\_\-command\_\-cd} & if true, this is a command that allows \char`\"{}change directory\char`\"{} inside \hyperlink{protocolthe-p}{the} CLI command-\/tree. \\
\hline
{\em command\_\-cd\_\-prompt} & if is\_\-command\_\-cd is true, \hyperlink{protocolthe-p}{the} string that will replace \hyperlink{protocolthe-p}{the} CLI prompt after we \char`\"{}cd\char`\"{} to that level of \hyperlink{protocolthe-p}{the} CLI command-\/tree. \\
\hline
{\em is\_\-command\_\-processor} & if true, this is a processing command that would be performed by . \\
\hline
{\em error\_\-msg} & \hyperlink{protocolthe-p}{the} error message (if error).\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
XORP\_\-OK on success, otherwise XORP\_\-ERROR. 
\end{DoxyReturn}
\hypertarget{classCliNode_ab6ca2e8448368683d0f99965e2bda587}{
\index{CliNode@{CliNode}!add\_\-client@{add\_\-client}}
\index{add\_\-client@{add\_\-client}!CliNode@{CliNode}}
\subsubsection[{add\_\-client}]{\setlength{\rightskip}{0pt plus 5cm}{\bf CliClient} $\ast$ CliNode::add\_\-client (
\begin{DoxyParamCaption}
\item[{{\bf XorpFd}}]{input\_\-fd, }
\item[{{\bf XorpFd}}]{output\_\-fd, }
\item[{bool}]{is\_\-network, }
\item[{const string \&}]{startup\_\-cli\_\-prompt, }
\item[{string \&}]{error\_\-msg}
\end{DoxyParamCaption}
)}}
\label{classCliNode_ab6ca2e8448368683d0f99965e2bda587}


Add a CLI client (\hyperlink{classCliClient}{CliClient}) to \hyperlink{protocolthe-p}{the} CLI with enabled access from a file descriptor. 


\begin{DoxyParams}{Parameters}
{\em input\_\-fd} & \hyperlink{protocolthe-p}{the} file descriptor for \hyperlink{protocolthe-p}{the} CLI client to read data from. \\
\hline
{\em output\_\-fd} & \hyperlink{protocolthe-p}{the} file descriptor for \hyperlink{protocolthe-p}{the} CLI client to write data to. \\
\hline
{\em is\_\-network} & if true, this client is associated with a network connection. \\
\hline
{\em startup\_\-cli\_\-prompt} & \hyperlink{protocolthe-p}{the} startup CLI prompt. \\
\hline
{\em error\_\-msg} & \hyperlink{protocolthe-p}{the} error message (if error). \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
a pointer to \hyperlink{protocolthe-p}{the} CLI client (\hyperlink{classCliClient}{CliClient}) with enabled CLI access on success, otherwise NULL. 
\end{DoxyReturn}
\hypertarget{classCliNode_a3de2e9b3d0574cac2035e19ae767c250}{
\index{CliNode@{CliNode}!add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet@{add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}}
\index{add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet@{add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}!CliNode@{CliNode}}
\subsubsection[{add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet (
\begin{DoxyParamCaption}
\item[{const {\bf IPvXNet} \&}]{subnet\_\-addr}
\end{DoxyParamCaption}
)}}
\label{classCliNode_a3de2e9b3d0574cac2035e19ae767c250}


Add a subnet address to \hyperlink{protocolthe-p}{the} list of subnet addresses disabled for CLI access. 

\hyperlink{classCliNode_a3de2e9b3d0574cac2035e19ae767c250}{CliNode::add\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}: : The subnet address to add.

This method can be called more than once to add a number of subnet addresses.


\begin{DoxyParams}{Parameters}
{\em subnet\_\-addr} & \hyperlink{protocolthe-p}{the} subnet address to add.\\
\hline
\end{DoxyParams}
Add a subnet address to \hyperlink{protocolthe-p}{the} list of subnet addresses disabled for CLI access. This method can be called more than once to add a number of subnet addresses. \hypertarget{classCliNode_ae216cb28dfbc044560c173a83948490a}{
\index{CliNode@{CliNode}!add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet@{add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}}
\index{add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet@{add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}!CliNode@{CliNode}}
\subsubsection[{add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet (
\begin{DoxyParamCaption}
\item[{const {\bf IPvXNet} \&}]{subnet\_\-addr}
\end{DoxyParamCaption}
)}}
\label{classCliNode_ae216cb28dfbc044560c173a83948490a}


Add a subnet address to \hyperlink{protocolthe-p}{the} list of subnet addresses enabled for CLI access. 

\hyperlink{classCliNode_ae216cb28dfbc044560c173a83948490a}{CliNode::add\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}: : The subnet address to add.

This method can be called more than once to add a number of subnet addresses.


\begin{DoxyParams}{Parameters}
{\em subnet\_\-addr} & \hyperlink{protocolthe-p}{the} subnet address to add.\\
\hline
\end{DoxyParams}
Add a subnet address to \hyperlink{protocolthe-p}{the} list of subnet addresses enabled for CLI access. This method can be called more than once to add a number of subnet addresses. \hypertarget{classCliNode_ab80706e4b958b6f2b45119a765702004}{
\index{CliNode@{CliNode}!add\_\-internal\_\-cli\_\-commands@{add\_\-internal\_\-cli\_\-commands}}
\index{add\_\-internal\_\-cli\_\-commands@{add\_\-internal\_\-cli\_\-commands}!CliNode@{CliNode}}
\subsubsection[{add\_\-internal\_\-cli\_\-commands}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::add\_\-internal\_\-cli\_\-commands (
\begin{DoxyParamCaption}
\item[{string \&}]{error\_\-msg}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{classCliNode_ab80706e4b958b6f2b45119a765702004}


\hyperlink{classCliNode_ab80706e4b958b6f2b45119a765702004}{CliNode::add\_\-internal\_\-cli\_\-commands}: : The error message (if error). 

Add \hyperlink{protocolthe-p}{the} internal default CLI commands from \hyperlink{protocolthe-p}{the} top. XXX: used by \hyperlink{protocolthe-p}{the} CLI itself for internal processing of a command. TODO: for consistency, even \hyperlink{protocolthe-p}{the} internal commands should use XRLs instead.

Return value: XORP\_\-OK on success, otherwise XORP\_\-ERROR. \hypertarget{classCliNode_ac9db32d54a94c76809ce2d968ff0817f}{
\index{CliNode@{CliNode}!cli\_\-command\_\-root@{cli\_\-command\_\-root}}
\index{cli\_\-command\_\-root@{cli\_\-command\_\-root}!CliNode@{CliNode}}
\subsubsection[{cli\_\-command\_\-root}]{\setlength{\rightskip}{0pt plus 5cm}{\bf CliCommand}$\ast$ CliNode::cli\_\-command\_\-root (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classCliNode_ac9db32d54a94c76809ce2d968ff0817f}


Get \hyperlink{protocolthe-p}{the} \hyperlink{classCliCommand}{CliCommand} entry for \hyperlink{protocolthe-p}{the} CLI root command. 

\begin{DoxyReturn}{Returns}
a pointer to \hyperlink{protocolthe-p}{the} \hyperlink{classCliCommand}{CliCommand} entry for \hyperlink{protocolthe-p}{the} CLI root command. 
\end{DoxyReturn}
\hypertarget{classCliNode_a8a27be0d016c5b0e2090e78fa38cf199}{
\index{CliNode@{CliNode}!client\_\-list@{client\_\-list}}
\index{client\_\-list@{client\_\-list}!CliNode@{CliNode}}
\subsubsection[{client\_\-list}]{\setlength{\rightskip}{0pt plus 5cm}list$<${\bf CliClient} $\ast$$>$\& CliNode::client\_\-list (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classCliNode_a8a27be0d016c5b0e2090e78fa38cf199}


Get \hyperlink{protocolthe-p}{the} list of CLI clients (see \hyperlink{classCliClient}{CliClient}). 

\begin{DoxyReturn}{Returns}
a reference to \hyperlink{protocolthe-p}{the} list of pointers to CLI clients (see \hyperlink{classCliClient}{CliClient}). 
\end{DoxyReturn}
\hypertarget{classCliNode_accc870d97a3a6463d671e9997969d496}{
\index{CliNode@{CliNode}!delete\_\-cli\_\-command@{delete\_\-cli\_\-command}}
\index{delete\_\-cli\_\-command@{delete\_\-cli\_\-command}!CliNode@{CliNode}}
\subsubsection[{delete\_\-cli\_\-command}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::delete\_\-cli\_\-command (
\begin{DoxyParamCaption}
\item[{const string \&}]{processor\_\-name, }
\item[{const string \&}]{command\_\-name, }
\item[{string \&}]{error\_\-msg}
\end{DoxyParamCaption}
)}}
\label{classCliNode_accc870d97a3a6463d671e9997969d496}


Delete a CLI command from \hyperlink{protocolthe-p}{the} CLI manager. 


\begin{DoxyParams}{Parameters}
{\em processor\_\-name} & \hyperlink{protocolthe-p}{the} name of \hyperlink{protocolthe-p}{the} module that is processing that command. \\
\hline
{\em command\_\-name} & \hyperlink{protocolthe-p}{the} name of \hyperlink{protocolthe-p}{the} command to delete. \\
\hline
{\em error\_\-msg} & \hyperlink{protocolthe-p}{the} error message (if error). \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
XORP\_\-OK on success, otherwise XORP\_\-ERROR. 
\end{DoxyReturn}
\hypertarget{classCliNode_add71d03105e22bac894967b64eff8213}{
\index{CliNode@{CliNode}!delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet@{delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}}
\index{delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet@{delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}!CliNode@{CliNode}}
\subsubsection[{delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet (
\begin{DoxyParamCaption}
\item[{const {\bf IPvXNet} \&}]{subnet\_\-addr}
\end{DoxyParamCaption}
)}}
\label{classCliNode_add71d03105e22bac894967b64eff8213}


Delete a subnet address from \hyperlink{protocolthe-p}{the} list of subnet addresses disabled for CLI access. 

\hyperlink{classCliNode_add71d03105e22bac894967b64eff8213}{CliNode::delete\_\-disable\_\-cli\_\-access\_\-from\_\-subnet}: : The subnet address to delete.


\begin{DoxyParams}{Parameters}
{\em subnet\_\-addr} & \hyperlink{protocolthe-p}{the} subnet address to delete. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
XORP\_\-OK on success, otherwise XORP\_\-ERROR (e.g., if \hyperlink{protocolthe-p}{the} subnet address was not added before).
\end{DoxyReturn}
Delete a subnet address from \hyperlink{protocolthe-p}{the} list of subnet addresses disabled for CLI access.

Return value: XORP\_\-OK on success, otherwise XORP\_\-ERROR. \hypertarget{classCliNode_af03427426adf491b17353adb9191aad6}{
\index{CliNode@{CliNode}!delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet@{delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}}
\index{delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet@{delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}!CliNode@{CliNode}}
\subsubsection[{delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet (
\begin{DoxyParamCaption}
\item[{const {\bf IPvXNet} \&}]{subnet\_\-addr}
\end{DoxyParamCaption}
)}}
\label{classCliNode_af03427426adf491b17353adb9191aad6}


Delete a subnet address from \hyperlink{protocolthe-p}{the} list of subnet addresses enabled for CLI access. 

\hyperlink{classCliNode_af03427426adf491b17353adb9191aad6}{CliNode::delete\_\-enable\_\-cli\_\-access\_\-from\_\-subnet}: : The subnet address to delete.


\begin{DoxyParams}{Parameters}
{\em subnet\_\-addr} & \hyperlink{protocolthe-p}{the} subnet address to delete. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
XORP\_\-OK on success, otherwise XORP\_\-ERROR (e.g., if \hyperlink{protocolthe-p}{the} subnet address was not added before).
\end{DoxyReturn}
Delete a subnet address from \hyperlink{protocolthe-p}{the} list of subnet addresses enabled for CLI access.

Return value: XORP\_\-OK on success, otherwise XORP\_\-ERROR. \hypertarget{classCliNode_af5805d18583ba6ea5422144b009081ba}{
\index{CliNode@{CliNode}!disable@{disable}}
\index{disable@{disable}!CliNode@{CliNode}}
\subsubsection[{disable}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::disable (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classCliNode_af5805d18583ba6ea5422144b009081ba}


Disable node operation. 

Disable \hyperlink{protocolthe-p}{the} node operation.

If an unit is disabled, it cannot be start or pending-\/start. If \hyperlink{protocolthe-p}{the} unit was runnning, it will be stop first. 

Reimplemented from \hyperlink{classProtoState_a42bbb9a9fa9588ec66f62d99644f3c48}{ProtoState}.

\hypertarget{classCliNode_a8f260c6eaf7369bc30281600a24aa1aa}{
\index{CliNode@{CliNode}!enable@{enable}}
\index{enable@{enable}!CliNode@{CliNode}}
\subsubsection[{enable}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::enable (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classCliNode_a8f260c6eaf7369bc30281600a24aa1aa}


Enable node operation. 

Enable \hyperlink{protocolthe-p}{the} node operation.

If an unit is not enabled, it cannot be start, or pending-\/start. 

Reimplemented from \hyperlink{classProtoState_a9e91d1d442f873cf6bf914db996519e7}{ProtoState}.

\hypertarget{classCliNode_adf9061abc373387f3e3f55b69b361f94}{
\index{CliNode@{CliNode}!find\_\-cli\_\-by\_\-session\_\-id@{find\_\-cli\_\-by\_\-session\_\-id}}
\index{find\_\-cli\_\-by\_\-session\_\-id@{find\_\-cli\_\-by\_\-session\_\-id}!CliNode@{CliNode}}
\subsubsection[{find\_\-cli\_\-by\_\-session\_\-id}]{\setlength{\rightskip}{0pt plus 5cm}{\bf CliClient} $\ast$ CliNode::find\_\-cli\_\-by\_\-session\_\-id (
\begin{DoxyParamCaption}
\item[{uint32\_\-t}]{session\_\-id}
\end{DoxyParamCaption}
) const}}
\label{classCliNode_adf9061abc373387f3e3f55b69b361f94}


Find a CLI client \hyperlink{classCliClient}{CliClient} for a given session ID. 

\hyperlink{classCliNode_adf9061abc373387f3e3f55b69b361f94}{CliNode::find\_\-cli\_\-by\_\-session\_\-id}: : The CLI session ID to search for.


\begin{DoxyParams}{Parameters}
{\em session\_\-id} & \hyperlink{protocolthe-p}{the} CLI session ID to search for. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} CLI client \hyperlink{classCliClient}{CliClient} with session ID of session\_\-id on success, otherwise NULL.
\end{DoxyReturn}
Find a CLI client \hyperlink{classCliClient}{CliClient} for a given session ID.

Return value: The CLI client with session ID of  on success, otherwise NULL. \hypertarget{classCliNode_a2295f07f5b4b9d82b98fa6fd5d3343ef}{
\index{CliNode@{CliNode}!find\_\-cli\_\-by\_\-term\_\-name@{find\_\-cli\_\-by\_\-term\_\-name}}
\index{find\_\-cli\_\-by\_\-term\_\-name@{find\_\-cli\_\-by\_\-term\_\-name}!CliNode@{CliNode}}
\subsubsection[{find\_\-cli\_\-by\_\-term\_\-name}]{\setlength{\rightskip}{0pt plus 5cm}{\bf CliClient} $\ast$ CliNode::find\_\-cli\_\-by\_\-term\_\-name (
\begin{DoxyParamCaption}
\item[{const string \&}]{term\_\-name}
\end{DoxyParamCaption}
) const}}
\label{classCliNode_a2295f07f5b4b9d82b98fa6fd5d3343ef}


Find a CLI client \hyperlink{classCliClient}{CliClient} for a given terminal name. 

\hyperlink{classCliNode_a2295f07f5b4b9d82b98fa6fd5d3343ef}{CliNode::find\_\-cli\_\-by\_\-term\_\-name}: : The CLI terminal name to search for.


\begin{DoxyParams}{Parameters}
{\em term\_\-name} & \hyperlink{protocolthe-p}{the} CLI terminal name to search for. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{protocolthe-p}{the} CLI client \hyperlink{classCliClient}{CliClient} with name of term\_\-name on success, otherwise NULL.
\end{DoxyReturn}
Find a CLI client \hyperlink{classCliClient}{CliClient} for a given terminal name.

Return value: The CLI client with name of  on success, otherwise NULL. \hypertarget{classCliNode_a435c77f502407cd977ddb4e45f8f6e5e}{
\index{CliNode@{CliNode}!is\_\-log\_\-trace@{is\_\-log\_\-trace}}
\index{is\_\-log\_\-trace@{is\_\-log\_\-trace}!CliNode@{CliNode}}
\subsubsection[{is\_\-log\_\-trace}]{\setlength{\rightskip}{0pt plus 5cm}bool CliNode::is\_\-log\_\-trace (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classCliNode_a435c77f502407cd977ddb4e45f8f6e5e}


Test if trace log is enabled. 

This method is used to test whether to output trace log debug messges.

\begin{DoxyReturn}{Returns}
true if trace log is enabled, otherwise false. 
\end{DoxyReturn}
\hypertarget{classCliNode_a8fd9de908796fb6bc0214e45f4d814fc}{
\index{CliNode@{CliNode}!recv\_\-process\_\-command\_\-output@{recv\_\-process\_\-command\_\-output}}
\index{recv\_\-process\_\-command\_\-output@{recv\_\-process\_\-command\_\-output}!CliNode@{CliNode}}
\subsubsection[{recv\_\-process\_\-command\_\-output}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::recv\_\-process\_\-command\_\-output (
\begin{DoxyParamCaption}
\item[{const string $\ast$}]{processor\_\-name, }
\item[{const string $\ast$}]{cli\_\-term\_\-name, }
\item[{const uint32\_\-t $\ast$}]{cli\_\-session\_\-id, }
\item[{const string $\ast$}]{command\_\-output}
\end{DoxyParamCaption}
)}}
\label{classCliNode_a8fd9de908796fb6bc0214e45f4d814fc}


Process \hyperlink{protocolthe-p}{the} response of a command processed by a remote node. 


\begin{DoxyParams}{Parameters}
{\em processor\_\-name} & \hyperlink{protocolthe-p}{the} name of \hyperlink{protocolthe-p}{the} module that has processed that command. \\
\hline
{\em cli\_\-term\_\-name} & \hyperlink{protocolthe-p}{the} terminal name \hyperlink{protocolthe-p}{the} command was entered from. \\
\hline
{\em cli\_\-session\_\-id} & \hyperlink{protocolthe-p}{the} CLI session ID \hyperlink{protocolthe-p}{the} command was entered from. \\
\hline
{\em command\_\-output} & \hyperlink{protocolthe-p}{the} command output to process. \\
\hline
\end{DoxyParams}
\hypertarget{classCliNode_aa7d68faaca271a02061c5922495e27c7}{
\index{CliNode@{CliNode}!remove\_\-client@{remove\_\-client}}
\index{remove\_\-client@{remove\_\-client}!CliNode@{CliNode}}
\subsubsection[{remove\_\-client}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::remove\_\-client (
\begin{DoxyParamCaption}
\item[{{\bf CliClient} $\ast$}]{cli\_\-client, }
\item[{string \&}]{error\_\-msg}
\end{DoxyParamCaption}
)}}
\label{classCliNode_aa7d68faaca271a02061c5922495e27c7}


Remove a CLI client (\hyperlink{classCliClient}{CliClient}) from \hyperlink{protocolthe-p}{the} CLI. 

Note that \hyperlink{protocolthe-p}{the} CLI client object itself is not deleted.


\begin{DoxyParams}{Parameters}
{\em cli\_\-client} & \hyperlink{protocolthe-p}{the} CLI client (\hyperlink{classCliClient}{CliClient}) to remove. \\
\hline
{\em error\_\-msg} & \hyperlink{protocolthe-p}{the} error message (if error). \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
XORP\_\-OK on success, otherwise XORP\_\-ERROR. 
\end{DoxyReturn}
\hypertarget{classCliNode_ab192e1ad6a0eafded6175df9ddf86922}{
\index{CliNode@{CliNode}!set\_\-cli\_\-client\_\-delete\_\-callback@{set\_\-cli\_\-client\_\-delete\_\-callback}}
\index{set\_\-cli\_\-client\_\-delete\_\-callback@{set\_\-cli\_\-client\_\-delete\_\-callback}!CliNode@{CliNode}}
\subsubsection[{set\_\-cli\_\-client\_\-delete\_\-callback}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::set\_\-cli\_\-client\_\-delete\_\-callback (
\begin{DoxyParamCaption}
\item[{const CliClientDeleteCallback \&}]{v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classCliNode_ab192e1ad6a0eafded6175df9ddf86922}


Set \hyperlink{protocolthe-p}{the} callback method that is invoked whenever a \hyperlink{classCliClient}{CliClient} is deleted. 


\begin{DoxyParams}{Parameters}
{\em v} & \hyperlink{protocolthe-p}{the} CliClientDeleteCallback callback to set. \\
\hline
\end{DoxyParams}
\hypertarget{classCliNode_aa45b8d4f270533aa740bcfb4ec6c2869}{
\index{CliNode@{CliNode}!set\_\-cli\_\-port@{set\_\-cli\_\-port}}
\index{set\_\-cli\_\-port@{set\_\-cli\_\-port}!CliNode@{CliNode}}
\subsubsection[{set\_\-cli\_\-port}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::set\_\-cli\_\-port (
\begin{DoxyParamCaption}
\item[{unsigned short}]{v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classCliNode_aa45b8d4f270533aa740bcfb4ec6c2869}


Set \hyperlink{protocolthe-p}{the} CLI access port. 

The access port is \hyperlink{protocolthe-p}{the} TCP port \hyperlink{protocolthe-p}{the} CLI node listens to for network access (e.g., telnet xorp\_\-host $<$port\_\-number$>$).


\begin{DoxyParams}{Parameters}
{\em v} & \hyperlink{protocolthe-p}{the} access port number (in host order). \\
\hline
\end{DoxyParams}
\hypertarget{classCliNode_a2da662f867e234852f5bba1b24e2d5ec}{
\index{CliNode@{CliNode}!set\_\-log\_\-trace@{set\_\-log\_\-trace}}
\index{set\_\-log\_\-trace@{set\_\-log\_\-trace}!CliNode@{CliNode}}
\subsubsection[{set\_\-log\_\-trace}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::set\_\-log\_\-trace (
\begin{DoxyParamCaption}
\item[{bool}]{is\_\-enabled}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classCliNode_a2da662f867e234852f5bba1b24e2d5ec}


Enable/disable trace log. 

This method is used to enable/disable trace log debug messages output.


\begin{DoxyParams}{Parameters}
{\em is\_\-enabled} & if true, trace log is enabled, otherwise is disabled. \\
\hline
\end{DoxyParams}
\hypertarget{classCliNode_aaf1faa816fe88d1dc595a10e8f257d66}{
\index{CliNode@{CliNode}!set\_\-send\_\-process\_\-command\_\-callback@{set\_\-send\_\-process\_\-command\_\-callback}}
\index{set\_\-send\_\-process\_\-command\_\-callback@{set\_\-send\_\-process\_\-command\_\-callback}!CliNode@{CliNode}}
\subsubsection[{set\_\-send\_\-process\_\-command\_\-callback}]{\setlength{\rightskip}{0pt plus 5cm}void CliNode::set\_\-send\_\-process\_\-command\_\-callback (
\begin{DoxyParamCaption}
\item[{const SenderProcessCallback \&}]{v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{classCliNode_aaf1faa816fe88d1dc595a10e8f257d66}


Set a callback to send a CLI command to a processing module. 


\begin{DoxyParams}{Parameters}
{\em v} & \hyperlink{protocolthe-p}{the} SenderProcessCallback callback to set. \\
\hline
\end{DoxyParams}
\hypertarget{classCliNode_a89d2da28f650829befe92a2cf10463c3}{
\index{CliNode@{CliNode}!sock\_\-serv\_\-close@{sock\_\-serv\_\-close}}
\index{sock\_\-serv\_\-close@{sock\_\-serv\_\-close}!CliNode@{CliNode}}
\subsubsection[{sock\_\-serv\_\-close}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::sock\_\-serv\_\-close (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{classCliNode_a89d2da28f650829befe92a2cf10463c3}


\hyperlink{classCliNode_a89d2da28f650829befe92a2cf10463c3}{CliNode::sock\_\-serv\_\-close}: @: 

Close \hyperlink{protocolthe-p}{the} socket that is used by \hyperlink{protocolthe-p}{the} CLI to listen on for connections.

Return value: XORP\_\-OK on success, otherwise XORP\_\-ERROR. \hypertarget{classCliNode_abd410a3ec9fe345def7fb96eb0451403}{
\index{CliNode@{CliNode}!sock\_\-serv\_\-open@{sock\_\-serv\_\-open}}
\index{sock\_\-serv\_\-open@{sock\_\-serv\_\-open}!CliNode@{CliNode}}
\subsubsection[{sock\_\-serv\_\-open}]{\setlength{\rightskip}{0pt plus 5cm}{\bf XorpFd} CliNode::sock\_\-serv\_\-open (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{classCliNode_abd410a3ec9fe345def7fb96eb0451403}


\hyperlink{classCliNode_abd410a3ec9fe345def7fb96eb0451403}{CliNode::sock\_\-serv\_\-open}: 

Open a socket for \hyperlink{protocolthe-p}{the} CLI to listen on for connections.

Return value: The new socket to listen on success, othewise a XockFd that contains an invalid socket. \hypertarget{classCliNode_acfe69d3c37b7fd6ee5fc60cd04693fbc}{
\index{CliNode@{CliNode}!start@{start}}
\index{start@{start}!CliNode@{CliNode}}
\subsubsection[{start}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::start (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classCliNode_acfe69d3c37b7fd6ee5fc60cd04693fbc}


Start \hyperlink{protocolthe-p}{the} node operation. 

\begin{DoxyReturn}{Returns}
XORP\_\-OK on success, otherwise XORP\_\-ERROR. 
\end{DoxyReturn}


Reimplemented from \hyperlink{classProtoState_a5a0cf7fc68b9db681ce8b8fca9635e07}{ProtoState}.

\hypertarget{classCliNode_a48ea54e6748aad1de1716ed157d95106}{
\index{CliNode@{CliNode}!stop@{stop}}
\index{stop@{stop}!CliNode@{CliNode}}
\subsubsection[{stop}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::stop (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classCliNode_a48ea54e6748aad1de1716ed157d95106}


Stop \hyperlink{protocolthe-p}{the} node operation. 

\hyperlink{classCliNode_a48ea54e6748aad1de1716ed157d95106}{CliNode::stop}: @:

\begin{DoxyReturn}{Returns}
XORP\_\-OK on success, otherwise XORP\_\-ERROR.
\end{DoxyReturn}
Stop \hyperlink{protocolthe-p}{the} CLI operation.

Return value: XORP\_\-OK on success, otherwise XORP\_\-ERROR. 

Reimplemented from \hyperlink{classProtoState_a00a8d35d02b0ce61a6b012326e81878c}{ProtoState}.

\hypertarget{classCliNode_a3900062d57140d5c807d56b8c3c65471}{
\index{CliNode@{CliNode}!xlog\_\-output@{xlog\_\-output}}
\index{xlog\_\-output@{xlog\_\-output}!CliNode@{CliNode}}
\subsubsection[{xlog\_\-output}]{\setlength{\rightskip}{0pt plus 5cm}int CliNode::xlog\_\-output (
\begin{DoxyParamCaption}
\item[{void $\ast$}]{obj, }
\item[{xlog\_\-level\_\-t}]{level, }
\item[{const char $\ast$}]{msg}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}static\mbox{]}}}}
\label{classCliNode_a3900062d57140d5c807d56b8c3c65471}


\hyperlink{classOutput}{Output} a log message to a \hyperlink{classCliClient}{CliClient} object. 

\hyperlink{classCliNode_a3900062d57140d5c807d56b8c3c65471}{CliNode::xlog\_\-output}: : The \hyperlink{classCliClient}{CliClient} object to apply this function to.


\begin{DoxyParams}{Parameters}
{\em obj} & \hyperlink{protocolthe-p}{the} \hyperlink{classCliClient}{CliClient} object to apply this method to. \\
\hline
{\em level} & \hyperlink{protocolthe-p}{the} XLOG level. \\
\hline
{\em msg} & a C-\/style string with \hyperlink{protocolthe-p}{the} message to output. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
on success, \hyperlink{protocolthe-p}{the} number of characters printed, otherwise XORP\_\-ERROR.
\end{DoxyReturn}
: A C-\/style string with \hyperlink{protocolthe-p}{the} message to output.

\hyperlink{classOutput}{Output} a log message to a \hyperlink{classCliClient}{CliClient} object.

Return value: On success, \hyperlink{protocolthe-p}{the} number of characters printed, otherwise XORP\_\-ERROR. 

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