\hypertarget{TOC_8h}{
\section{TOC.h File Reference}
\label{TOC_8h}\index{TOC.h@{TOC.h}}
}
Time\-Out Control, prototypes and public data structures. 

{\tt \#include \char`\"{}PBS/TOV.h\char`\"{}}\par
{\tt \#include \char`\"{}PBS/TOC\_\-comdefs.h\char`\"{}}\par


Include dependency graph for TOC.h:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=242pt]{TOC_8h__incl}
\end{center}
\end{figure}


This graph shows which files directly or indirectly include this file:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=280pt]{TOC_8h__dep__incl}
\end{center}
\end{figure}
\subsection*{Data Structures}
\begin{CompactItemize}
\item 
struct \hyperlink{struct__TOC__cvt__s}{\_\-TOC\_\-cvt\_\-s}
\begin{CompactList}\small\item\em Structure specifying the conversion of an small range timeout (TOS) to a timeout value (TOV), via user provided TOV\_\-cvt\_\-s function. \item\end{CompactList}\item 
struct \hyperlink{struct__TOC__cvt__v}{\_\-TOC\_\-cvt\_\-v}
\begin{CompactList}\small\item\em Structure specifying the timeout is being provided as an immediate timeout value (TOV). \item\end{CompactList}\item 
struct \hyperlink{struct__TOC__cvt__x}{\_\-TOC\_\-cvt\_\-x}
\begin{CompactList}\small\item\em Structure specifying the conversion of an unsigned int to a timeout value (TOV), via user provided TOV\_\-cvt\_\-x style function. \item\end{CompactList}\item 
union \hyperlink{union__TOC__cvt}{\_\-TOC\_\-cvt}
\begin{CompactList}\small\item\em A union of the all the converter styles. \item\end{CompactList}\item 
struct \hyperlink{struct__TOC}{\_\-TOC}
\begin{CompactList}\small\item\em The timeout conversion control structure. \item\end{CompactList}\end{CompactItemize}
\subsection*{Typedefs}
\begin{CompactItemize}
\item 
typedef enum \hyperlink{TOC_8h_a15}{\_\-TOC\_\-style} \hyperlink{TOC_8h_a0}{TOC\_\-style}
\item 
typedef \hyperlink{struct__TOC__cvt__s}{\_\-TOC\_\-cvt\_\-s} \hyperlink{TOC_8h_a1}{TOC\_\-cvt\_\-s}
\begin{CompactList}\small\item\em Typedef for struct {\em \hyperlink{struct__TOC__cvt__s}{\_\-TOC\_\-cvt\_\-s}\/}. \item\end{CompactList}\item 
typedef \hyperlink{struct__TOC__cvt__v}{\_\-TOC\_\-cvt\_\-v} \hyperlink{TOC_8h_a2}{TOC\_\-cvt\_\-v}
\begin{CompactList}\small\item\em Typedef for struct {\em \hyperlink{struct__TOC__cvt__v}{\_\-TOC\_\-cvt\_\-v}\/}. \item\end{CompactList}\item 
typedef \hyperlink{struct__TOC__cvt__x}{\_\-TOC\_\-cvt\_\-x} \hyperlink{TOC_8h_a3}{TOC\_\-cvt\_\-x}
\begin{CompactList}\small\item\em Typedef for struct {\em \hyperlink{struct__TOC__cvt__x}{\_\-TOC\_\-cvt\_\-x}\/}. \item\end{CompactList}\item 
\hypertarget{TOC_8h_a4}{
typedef \hyperlink{union__TOC__cvt}{\_\-TOC\_\-cvt} \hyperlink{TOC_8h_a4}{TOC\_\-cvt}}
\label{TOC_8h_a4}

\begin{CompactList}\small\item\em Typedef for union {\em \hyperlink{union__TOC__cvt}{\_\-TOC\_\-cvt}\/}. \item\end{CompactList}\end{CompactItemize}
\subsection*{Enumerations}
\begin{CompactItemize}
\item 
enum \hyperlink{TOC_8h_a15}{\_\-TOC\_\-style} \{ \par
\hyperlink{TOC_8h_a15a5}{TOC\_\-K\_\-STYLE\_\-S} =  -1, 
\par
\hyperlink{TOC_8h_a15a6}{TOC\_\-K\_\-STYLE\_\-V} =  0, 
\par
\hyperlink{TOC_8h_a15a7}{TOC\_\-K\_\-STYLE\_\-X} =  1
 \}
\begin{CompactList}\small\item\em Enumerates the different way that a timeout may be specified. \item\end{CompactList}\end{CompactItemize}
\subsection*{Functions}
\begin{CompactItemize}
\item 
void \hyperlink{TOC_8h_a8}{TOC\_\-set\_\-s} (\hyperlink{struct__TOC}{TOC} $\ast$toc, \hyperlink{TOV_8h_a1}{TOV\_\-cvt\_\-s} fnc, \hyperlink{TOC__comdefs_8h_a8}{TOS} tmo)
\begin{CompactList}\small\item\em Sets the TOV converter and value for small range timeouts. \item\end{CompactList}\item 
void \hyperlink{TOC_8h_a9}{TOC\_\-set\_\-v} (\hyperlink{struct__TOC}{TOC} $\ast$toc, \hyperlink{TOV_8h_8px-xxx-xxx_a8}{TOV} tmo)
\begin{CompactList}\small\item\em Sets the TOV converter and value for an immediate TOV. \item\end{CompactList}\item 
void \hyperlink{TOC_8h_a10}{TOC\_\-set\_\-x} (\hyperlink{struct__TOC}{TOC} $\ast$toc, \hyperlink{TOV_8h_a2}{TOV\_\-cvt\_\-x} fnc, \hyperlink{TOC__comdefs_8h_a9}{TOX} tmo)
\begin{CompactList}\small\item\em Sets the TOV converter and value for extended range timeouts. \item\end{CompactList}\item 
void \hyperlink{TOC_8h_a11}{TOC\_\-reset\_\-tos} (\hyperlink{struct__TOC}{TOC} $\ast$toc, \hyperlink{TOC__comdefs_8h_a8}{TOS} tmo)
\begin{CompactList}\small\item\em Resets the small range timeout value. The timeout conversion routine is assumed to be have previously set using TOC\_\-set\_\-s. \item\end{CompactList}\item 
void \hyperlink{TOC_8h_a12}{TOC\_\-reset\_\-tov} (\hyperlink{struct__TOC}{TOC} $\ast$toc, \hyperlink{TOV_8h_8px-xxx-xxx_a8}{TOV} tmo)
\begin{CompactList}\small\item\em Resets the immediate timeout value. The timeout conversion routine is assumed to be have previously set using TOC\_\-set\_\-v. \item\end{CompactList}\item 
void \hyperlink{TOC_8h_a13}{TOC\_\-reset\_\-tox} (\hyperlink{struct__TOC}{TOC} $\ast$toc, \hyperlink{TOC__comdefs_8h_a9}{TOX} tmo)
\begin{CompactList}\small\item\em Resets the extended range timeout value. The timeout conversion routine is assumed to be have previously set using TOC\_\-set\_\-x. \item\end{CompactList}\item 
\hyperlink{TOV_8h_8px-xxx-xxx_a8}{TOV} \hyperlink{TOC_8h_a14}{TOC\_\-compute} (const \hyperlink{struct__TOC}{TOC} $\ast$toc)
\begin{CompactList}\small\item\em Computes the timeout value (TOV) specified by the timeout control structure. \item\end{CompactList}\end{CompactItemize}


\subsection{Detailed Description}
Time\-Out Control, prototypes and public data structures. 

\begin{Desc}
\item[Author:]JJRussell - \href{mailto:russell@slac.stanford.edu}{\tt russell@slac.stanford.edu}\end{Desc}


\footnotesize\begin{verbatim}    CVS $Id: TOC.h,v 1.4 2005/05/02 15:39:39 russell Exp $
\end{verbatim}
\normalsize


\begin{Desc}
\item[SYNOPSIS]Provides a set of utility functions to define a timeout control structure. This structure is passed to most all routines that requirement implement a timeout. It serves as a universal method to convert a variety of time representations to a Time\-Out Value, TOV.\end{Desc}


\subsection{Typedef Documentation}
\hypertarget{TOC_8h_a1}{
\index{TOC.h@{TOC.h}!TOC_cvt_s@{TOC\_\-cvt\_\-s}}
\index{TOC_cvt_s@{TOC\_\-cvt\_\-s}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-cvt\_\-s]{\setlength{\rightskip}{0pt plus 5cm}\hyperlink{struct__TOC__cvt__s}{TOC\_\-cvt\_\-s}}}
\label{TOC_8h_a1}


Typedef for struct {\em \hyperlink{struct__TOC__cvt__s}{\_\-TOC\_\-cvt\_\-s}\/}. 

This is one of the conversion styles, specified by TOC\_\-styles, e.g. {\em TOC\_\-K\_\-STYLE\_\-CVT\_\-S\/}.\hypertarget{TOC_8h_a2}{
\index{TOC.h@{TOC.h}!TOC_cvt_v@{TOC\_\-cvt\_\-v}}
\index{TOC_cvt_v@{TOC\_\-cvt\_\-v}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-cvt\_\-v]{\setlength{\rightskip}{0pt plus 5cm}\hyperlink{struct__TOC__cvt__v}{TOC\_\-cvt\_\-v}}}
\label{TOC_8h_a2}


Typedef for struct {\em \hyperlink{struct__TOC__cvt__v}{\_\-TOC\_\-cvt\_\-v}\/}. 

This is one of the conversion styles, specified by TOC\_\-styles, e.g. {\em TOC\_\-K\_\-STYLE\_\-CVT\_\-V\/}.\hypertarget{TOC_8h_a3}{
\index{TOC.h@{TOC.h}!TOC_cvt_x@{TOC\_\-cvt\_\-x}}
\index{TOC_cvt_x@{TOC\_\-cvt\_\-x}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-cvt\_\-x]{\setlength{\rightskip}{0pt plus 5cm}\hyperlink{struct__TOC__cvt__x}{TOC\_\-cvt\_\-x}}}
\label{TOC_8h_a3}


Typedef for struct {\em \hyperlink{struct__TOC__cvt__x}{\_\-TOC\_\-cvt\_\-x}\/}. 

This is one of the conversion styles, specified by TOC\_\-styles, e.g. {\em TOC\_\-K\_\-STYLE\_\-CVT\_\-X\/}.\hypertarget{TOC_8h_a0}{
\index{TOC.h@{TOC.h}!TOC_style@{TOC\_\-style}}
\index{TOC_style@{TOC\_\-style}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-style]{\setlength{\rightskip}{0pt plus 5cm}\hyperlink{TOC_8h_a0}{TOC\_\-style}}}
\label{TOC_8h_a0}


brief Typedef for enum {\em \_\-TOC\_\-style\/} 

\begin{Desc}
\item[Warning:]This is an internal only data structure.\end{Desc}


\subsection{Enumeration Type Documentation}
\hypertarget{TOC_8h_a15}{
\index{TOC.h@{TOC.h}!_TOC_style@{\_\-TOC\_\-style}}
\index{_TOC_style@{\_\-TOC\_\-style}!TOC.h@{TOC.h}}
\subsubsection[\_\-TOC\_\-style]{\setlength{\rightskip}{0pt plus 5cm}enum \hyperlink{TOC_8h_a15}{\_\-TOC\_\-style}}}
\label{TOC_8h_a15}


Enumerates the different way that a timeout may be specified. 

\begin{Desc}
\item[Enumerator: ]\par
\begin{description}
\index{TOC_K_STYLE_S@{TOC\_\-K\_\-STYLE\_\-S}!TOC.h@{TOC.h}}\index{TOC.h@{TOC.h}!TOC_K_STYLE_S@{TOC\_\-K\_\-STYLE\_\-S}}\item[{\em 
\hypertarget{TOC_8h_a15a5}{
TOC\_\-K\_\-STYLE\_\-S}
\label{TOC_8h_a15a5}
}]Convert using a TOV\_\-cvt\_\-s function \index{TOC_K_STYLE_V@{TOC\_\-K\_\-STYLE\_\-V}!TOC.h@{TOC.h}}\index{TOC.h@{TOC.h}!TOC_K_STYLE_V@{TOC\_\-K\_\-STYLE\_\-V}}\item[{\em 
\hypertarget{TOC_8h_a15a6}{
TOC\_\-K\_\-STYLE\_\-V}
\label{TOC_8h_a15a6}
}]Value is already a TOV \index{TOC_K_STYLE_X@{TOC\_\-K\_\-STYLE\_\-X}!TOC.h@{TOC.h}}\index{TOC.h@{TOC.h}!TOC_K_STYLE_X@{TOC\_\-K\_\-STYLE\_\-X}}\item[{\em 
\hypertarget{TOC_8h_a15a7}{
TOC\_\-K\_\-STYLE\_\-X}
\label{TOC_8h_a15a7}
}]Convert using a TOV\_\-cvt\_\-x function \end{description}
\end{Desc}



\subsection{Function Documentation}
\hypertarget{TOC_8h_a14}{
\index{TOC.h@{TOC.h}!TOC_compute@{TOC\_\-compute}}
\index{TOC_compute@{TOC\_\-compute}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-compute]{\setlength{\rightskip}{0pt plus 5cm}\hyperlink{TOV_8h_8px-xxx-xxx_a8}{TOV} TOC\_\-compute (const \hyperlink{struct__TOC}{TOC} $\ast$ {\em toc})}}
\label{TOC_8h_a14}


Computes the timeout value (TOV) specified by the timeout control structure. 

\begin{Desc}
\item[Returns:]The timeout value specified by the timeout control structure\end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em toc}]The timeout control structure\end{description}
\end{Desc}
\hypertarget{TOC_8h_a11}{
\index{TOC.h@{TOC.h}!TOC_reset_tos@{TOC\_\-reset\_\-tos}}
\index{TOC_reset_tos@{TOC\_\-reset\_\-tos}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-reset\_\-tos]{\setlength{\rightskip}{0pt plus 5cm}void TOC\_\-reset\_\-tos (\hyperlink{struct__TOC}{TOC} $\ast$ {\em toc}, \hyperlink{TOC__comdefs_8h_a8}{TOS} {\em tmo})}}
\label{TOC_8h_a11}


Resets the small range timeout value. The timeout conversion routine is assumed to be have previously set using TOC\_\-set\_\-s. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em toc}]The target Timeout control structure. \item[{\em tmo}]The new small range timeout value to convert.\end{description}
\end{Desc}
\begin{Desc}
\item[Warning:]No check is made to assure that the conversion style is TOC\_\-K\_\-STYLE\_\-S. It is the user's responsibility to ensure this.\end{Desc}
\hypertarget{TOC_8h_a12}{
\index{TOC.h@{TOC.h}!TOC_reset_tov@{TOC\_\-reset\_\-tov}}
\index{TOC_reset_tov@{TOC\_\-reset\_\-tov}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-reset\_\-tov]{\setlength{\rightskip}{0pt plus 5cm}void TOC\_\-reset\_\-tov (\hyperlink{struct__TOC}{TOC} $\ast$ {\em toc}, \hyperlink{TOV_8h_8px-xxx-xxx_a8}{TOV} {\em tmo})}}
\label{TOC_8h_a12}


Resets the immediate timeout value. The timeout conversion routine is assumed to be have previously set using TOC\_\-set\_\-v. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em toc}]The target Timeout control structure. \item[{\em tmo}]The new extended range timeout value to convert.\end{description}
\end{Desc}
\begin{Desc}
\item[Warning:]No check is made to assure that the conversion style is TOC\_\-K\_\-STYLE\_\-V. It is the user's responsibility to ensure this.\end{Desc}
\hypertarget{TOC_8h_a13}{
\index{TOC.h@{TOC.h}!TOC_reset_tox@{TOC\_\-reset\_\-tox}}
\index{TOC_reset_tox@{TOC\_\-reset\_\-tox}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-reset\_\-tox]{\setlength{\rightskip}{0pt plus 5cm}void TOC\_\-reset\_\-tox (\hyperlink{struct__TOC}{TOC} $\ast$ {\em toc}, \hyperlink{TOC__comdefs_8h_a9}{TOX} {\em tmo})}}
\label{TOC_8h_a13}


Resets the extended range timeout value. The timeout conversion routine is assumed to be have previously set using TOC\_\-set\_\-x. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em toc}]The target Timeout control structure \item[{\em tmo}]The new extended range timeout value to convert.\end{description}
\end{Desc}
\begin{Desc}
\item[Warning:]No check is made to assure that the conversion style is TOC\_\-K\_\-STYLE\_\-X. It is the user's responsibility to ensure this.\end{Desc}
\hypertarget{TOC_8h_a8}{
\index{TOC.h@{TOC.h}!TOC_set_s@{TOC\_\-set\_\-s}}
\index{TOC_set_s@{TOC\_\-set\_\-s}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-set\_\-s]{\setlength{\rightskip}{0pt plus 5cm}void TOC\_\-set\_\-s (\hyperlink{struct__TOC}{TOC} $\ast$ {\em toc}, \hyperlink{TOV_8h_a1}{TOV\_\-cvt\_\-s} {\em fnc}, \hyperlink{TOC__comdefs_8h_a8}{TOS} {\em tos})}}
\label{TOC_8h_a8}


Sets the TOV converter and value for small range timeouts. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em toc}]The target Timeout control structure \item[{\em fnc}]The extended range to TOV converter function. \item[{\em tos}]The value to convert\end{description}
\end{Desc}
\hypertarget{TOC_8h_a9}{
\index{TOC.h@{TOC.h}!TOC_set_v@{TOC\_\-set\_\-v}}
\index{TOC_set_v@{TOC\_\-set\_\-v}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-set\_\-v]{\setlength{\rightskip}{0pt plus 5cm}void TOC\_\-set\_\-v (\hyperlink{struct__TOC}{TOC} $\ast$ {\em toc}, \hyperlink{TOV_8h_8px-xxx-xxx_a8}{TOV} {\em tmo})}}
\label{TOC_8h_a9}


Sets the TOV converter and value for an immediate TOV. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em toc}]The target Timeout control structure \item[{\em tmo}]The TOV value to set.\end{description}
\end{Desc}
\hypertarget{TOC_8h_a10}{
\index{TOC.h@{TOC.h}!TOC_set_x@{TOC\_\-set\_\-x}}
\index{TOC_set_x@{TOC\_\-set\_\-x}!TOC.h@{TOC.h}}
\subsubsection[TOC\_\-set\_\-x]{\setlength{\rightskip}{0pt plus 5cm}void TOC\_\-set\_\-x (\hyperlink{struct__TOC}{TOC} $\ast$ {\em toc}, \hyperlink{TOV_8h_a2}{TOV\_\-cvt\_\-x} {\em fnc}, \hyperlink{TOC__comdefs_8h_a9}{TOX} {\em tmo})}}
\label{TOC_8h_a10}


Sets the TOV converter and value for extended range timeouts. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em toc}]The target Timeout control structure. \item[{\em fnc}]The extended range to TOV converter. \item[{\em tmo}]The extended range timeout value to convert.\end{description}
\end{Desc}
