Commit e3f8b5df authored by Adam Wujek's avatar Adam Wujek 💬 Committed by Grzegorz Daniluk

doc/wrs_failures: add alphabetical index of all MIB objects

This commit causes slower generation of wrs_failures.pdf
To speed up for development, comment out:
% print alphabetical list
\printnoidxglossary[type=snmp_all,style=tree,sort=letter]
from doc/wrs_failures/snmp_exports.tex file.
Signed-off-by: Adam Wujek's avatarAdam Wujek <adam.wujek@cern.ch>
parent 3a99e6ba
......@@ -8,6 +8,10 @@ wrs_failures.pdf : wrs_failures.tex fail.tex intro.tex snmp_exports.tex snmp_obj
@echo '\\newcommand{\\gitrevinfo}{'$(RELEASE)'}' > revinfo.tex
pdflatex wrs_failures.tex
pdflatex wrs_failures.tex
# To speed up generation of document for development, please comment out:
# % print alphabetical list
# \printnoidxglossary[type=snmp_all,style=tree,sort=letter]
# from doc/wrs_failures/snmp_exports.tex file.
clean :
rm -f *.eps *.dat *.log *.out *.aux *.dvi *.ps *.toc *.pdf revinfo.tex
......
......@@ -411,9 +411,14 @@ between devices connected to the ports.\\
\snmpadd{WR-SWITCH-MIB::wrsPstatsFastMatchPriority.<n>} - HP frames on a port\\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXFrames.<n>} - Total number of Rx frames on
the port\\
\texttt{WR-SWITCh-MIB::wrsPstatsRXPrio0.<n>} - Rx priorities 0-7\\
\texttt{[..]}\\
\texttt{WR-SWITCh-MIB::wrsPstatsRXPrio7.<n>}
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio0.<n>} - Rx priorities 0-7\\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio1.<n>} \\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio2.<n>} \\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio3.<n>} \\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio4.<n>} \\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio5.<n>} \\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio6.<n>} \\
\snmpadd{WR-SWITCH-MIB::wrsPstatsRXPrio7.<n>}
\item [] \underline{Note}: we need to get from SwCore the information
about per-priority queue utilization, or at least an event when it's
full.
......
......@@ -58,6 +58,12 @@ this section can have one of the following values:
% other objects
\printnoidxglossary[type=snmp_other,style=objtree,sort=def]
\subsection{Sorted list of MIB objects}
\label{sec:snmp_exports:sorted}
% print alphabetical list
\printnoidxglossary[type=snmp_all,style=tree,sort=letter]
%%%%%%%%%%%%%%%%%%5
%% Other notes
%
......
......@@ -82,10 +82,13 @@
\newglossary*{snmp_status}{SNMP's status objects}
\newglossary*{snmp_expert}{SNMP's expert objects}
\newglossary*{snmp_other}{Objects from other MIBs}
% alphabetical list of all entries
\newglossary*{snmp_all}{All SNMP objects}
% default formating for alphabetical list, display nothing
\defglsentryfmt[snmp_all]{}
% macro to add entires
\newcommand{\snmpadd}[1]{
\texttt{\glspl{#1}}%
\texttt{\glspl{#1}}\glsdisp[hyper=false]{x#1}{}%
}
% helpers to add glossary entries
......@@ -98,13 +101,14 @@
\fi
}
% {MIB}{parent}{object}{comment}
% {MIB}{parent}{object}{comment}{glossary_name}
\newcommand{\snmpentry}[5]{%
\ifx&#2&% if parameter 2 is empty don't add parent
\newglossaryentry{#1::#3}{%
type=#5,%
name={#3},%
plural={#1::#3},% used to display name not plural
user1={#1},% MIB
description={\descr{#4}}%
}%
\else
......@@ -113,9 +117,16 @@
name={#3},%
description={\descr{#4}},%
plural={#1::#3},% used to display name not plural
user1={#1},% MIB
parent={#1::#2}%
}%
\fi
% add entry to alphabetical list
\newglossaryentry{x#1::#3}{%
type=snmp_all,%
name={#1::#3},%
description={}
}%
}
% {MIB}{parent}{object}{comment}
......@@ -148,7 +159,7 @@
\renewcommand{\glossentry}[2]{%
\hangindent30pt\relax
\parindent0pt\relax
--\kern 0.33em\glsentryitem{##1}\glstreenamefmt{\glstarget{##1}{\glossentryname{##1}}}%
--\kern 0.33em\glsentryitem{##1}\glstreenamefmt{\glstarget{##1}{\texttt{\textmd{\glsentryuseri{##1}}::}\glossentryname{##1}}}%
\ifglshassymbol{##1}{\kern 0.33em(\glossentrysymbol{##1})}{}%
\glossentrydesc{##1}\glspostdescription\kern 0.33em##2\par
}%
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment