
nico@207: \section{examples/Test\-Master\-Slave/getopt.c File Reference}
nico@207: \label{TestMasterSlave_2getopt_8c}\index{examples/TestMasterSlave/getopt.c@{examples/TestMasterSlave/getopt.c}}
nico@207: {\tt \#include $<$stdio.h$>$}\par
nico@207: {\tt \#include \char`\"{}getopt.h\char`\"{}}\par
nico@207: {\tt \#include $<$strings.h$>$}\par
nico@207: \subsection*{Defines}
nico@207: \begin{CompactItemize}
nico@207: \item 
nico@207: \#define {\bf GETOPT\_\-INTERFACE\_\-VERSION}~2
nico@207: \item 
nico@207: \#define {\bf \_\-}(msgid)~(msgid)
nico@207: \item 
nico@207: \#define {\bf SWAP\_\-FLAGS}(ch1, ch2)
nico@207: \item 
nico@207: \#define {\bf NONOPTION\_\-P}~(argv[{\bf optind}][0] != '-' $|$$|$ argv[{\bf optind}][1] == '$\backslash$0')
nico@207: \end{CompactItemize}
nico@207: \subsection*{Enumerations}
nico@207: \begin{CompactItemize}
nico@207: \item 
nico@207: enum \{ {\bf REQUIRE\_\-ORDER}, 
nico@207: {\bf PERMUTE}, 
nico@207: {\bf RETURN\_\-IN\_\-ORDER}
nico@207:  \}
nico@207: \end{CompactItemize}
nico@207: \subsection*{Functions}
nico@207: \begin{CompactItemize}
nico@207: \item 
nico@207: char $\ast$ {\bf getenv} ()
nico@207: \item 
nico@207: static char $\ast$ {\bf my\_\-index} (char $\ast$str, int chr) const
nico@207: \item 
nico@207: static void {\bf exchange} (char $\ast$$\ast$argv)
nico@207: \item 
nico@207: static const char $\ast$ {\bf \_\-getopt\_\-initialize} (int argc, char $\ast$const $\ast$argv, const char $\ast$optstring)
nico@207: \item 
nico@207: int {\bf \_\-getopt\_\-internal} (int argc, char $\ast$const $\ast$argv, const char $\ast$optstring, const struct {\bf option} $\ast$longopts, int $\ast$longind, int long\_\-only)
nico@207: \item 
nico@207: int {\bf getopt} (int argc, char $\ast$const $\ast$argv, const char $\ast$optstring)
nico@207: \end{CompactItemize}
nico@207: \subsection*{Variables}
nico@207: \begin{CompactItemize}
nico@207: \item 
nico@207: char $\ast$ {\bf optarg}
nico@207: \item 
nico@207: int {\bf optind} = 1
nico@207: \item 
nico@207: int {\bf \_\-\_\-getopt\_\-initialized}
nico@207: \item 
nico@207: static char $\ast$ {\bf nextchar}
nico@207: \item 
nico@207: int {\bf opterr} = 1
nico@207: \item 
nico@207: int {\bf optopt} = '?'
nico@207: \item 
nico@207: static enum  \{ ... \}  {\bf ordering}
nico@207: \item 
nico@207: static char $\ast$ {\bf posixly\_\-correct}
nico@207: \item 
nico@207: static int {\bf first\_\-nonopt}
nico@207: \item 
nico@207: static int {\bf last\_\-nonopt}
nico@207: \end{CompactItemize}
nico@207: 
nico@207: 
nico@207: \subsection{Define Documentation}
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!_@{\_\-}}
nico@207: \index{_@{\_\-}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}\#define \_\-(msgid)~(msgid)}\label{TestMasterSlave_2getopt_8c_86a239addea586602343007a370bf8ad}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!GETOPT_INTERFACE_VERSION@{GETOPT\_\-INTERFACE\_\-VERSION}}
nico@207: \index{GETOPT_INTERFACE_VERSION@{GETOPT\_\-INTERFACE\_\-VERSION}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}\#define GETOPT\_\-INTERFACE\_\-VERSION~2}\label{TestMasterSlave_2getopt_8c_5325c715897861c318d3ae312ac452cc}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!NONOPTION_P@{NONOPTION\_\-P}}
nico@207: \index{NONOPTION_P@{NONOPTION\_\-P}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}\#define NONOPTION\_\-P~(argv[{\bf optind}][0] != '-' $|$$|$ argv[{\bf optind}][1] == '$\backslash$0')}\label{TestMasterSlave_2getopt_8c_71ceb8911d64b39b402041ba5ea8453c}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!SWAP_FLAGS@{SWAP\_\-FLAGS}}
nico@207: \index{SWAP_FLAGS@{SWAP\_\-FLAGS}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}\#define SWAP\_\-FLAGS(ch1, ch2)}\label{TestMasterSlave_2getopt_8c_6e06e56c5fa96faaf47f3b231e015e35}
nico@207: 
nico@207: 
nico@207: 
nico@207: 
nico@207: \subsection{Enumeration Type Documentation}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}anonymous enum}\label{TestMasterSlave_2getopt_8c_df764cbdea00d65edcd07bb9953ad2b7}
nico@207: 
nico@207: 
nico@207: \begin{Desc}
nico@207: \item[Enumerator: ]\par
nico@207: \begin{description}
nico@207: \index{REQUIRE_ORDER@{REQUIRE\_\-ORDER}!TestMasterSlave/getopt.c@{TestMasterSlave/getopt.c}}\index{TestMasterSlave/getopt.c@{TestMasterSlave/getopt.c}!REQUIRE_ORDER@{REQUIRE\_\-ORDER}}\item[{\em 
nico@207: REQUIRE\_\-ORDER\label{TestMasterSlave_2getopt_8c_df764cbdea00d65edcd07bb9953ad2b70e73a0691c110b1442d8364d1d12eccc}
nico@207: }]\index{PERMUTE@{PERMUTE}!TestMasterSlave/getopt.c@{TestMasterSlave/getopt.c}}\index{TestMasterSlave/getopt.c@{TestMasterSlave/getopt.c}!PERMUTE@{PERMUTE}}\item[{\em 
nico@207: PERMUTE\label{TestMasterSlave_2getopt_8c_df764cbdea00d65edcd07bb9953ad2b7cfdde4b47c27f4efbd832e1ac7f8a8fc}
nico@207: }]\index{RETURN_IN_ORDER@{RETURN\_\-IN\_\-ORDER}!TestMasterSlave/getopt.c@{TestMasterSlave/getopt.c}}\index{TestMasterSlave/getopt.c@{TestMasterSlave/getopt.c}!RETURN_IN_ORDER@{RETURN\_\-IN\_\-ORDER}}\item[{\em 
nico@207: RETURN\_\-IN\_\-ORDER\label{TestMasterSlave_2getopt_8c_df764cbdea00d65edcd07bb9953ad2b73c56550bfafe809d9214b863b69c31c5}
nico@207: }]\end{description}
nico@207: \end{Desc}
nico@207: 
nico@207: 
nico@207: 
nico@207: \subsection{Function Documentation}
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!_getopt_initialize@{\_\-getopt\_\-initialize}}
nico@207: \index{_getopt_initialize@{\_\-getopt\_\-initialize}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}static const char$\ast$ \_\-getopt\_\-initialize (int {\em argc}, char $\ast$const $\ast$ {\em argv}, const char $\ast$ {\em optstring})\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_17475cbc1ffae0c12af2e0a3319d197f}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!_getopt_internal@{\_\-getopt\_\-internal}}
nico@207: \index{_getopt_internal@{\_\-getopt\_\-internal}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int \_\-getopt\_\-internal (int {\em argc}, char $\ast$const $\ast$ {\em argv}, const char $\ast$ {\em optstring}, const struct {\bf option} $\ast$ {\em longopts}, int $\ast$ {\em longind}, int {\em long\_\-only})}\label{TestMasterSlave_2getopt_8c_0df92a0ae8fe1fd43268c738f548674f}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!exchange@{exchange}}
nico@207: \index{exchange@{exchange}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}static void exchange (char $\ast$$\ast$ {\em argv})\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_4621659dd6377e52ac50a0869625bb6e}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!getenv@{getenv}}
nico@207: \index{getenv@{getenv}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ getenv ()}\label{TestMasterSlave_2getopt_8c_ee28fd8a0e40b6d958f7d20348e45368}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!getopt@{getopt}}
nico@207: \index{getopt@{getopt}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int getopt (int {\em argc}, char $\ast$const $\ast$ {\em argv}, const char $\ast$ {\em optstring})}\label{TestMasterSlave_2getopt_8c_1b2ada39ab92162c6ec9c67c8093fa2e}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!my_index@{my\_\-index}}
nico@207: \index{my_index@{my\_\-index}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}static char$\ast$ my\_\-index (char $\ast$ {\em str}, int {\em chr}) const\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_e0ac978b7775f69496c0f127ffdada9d}
nico@207: 
nico@207: 
nico@207: 
nico@207: 
nico@207: \subsection{Variable Documentation}
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!__getopt_initialized@{\_\-\_\-getopt\_\-initialized}}
nico@207: \index{__getopt_initialized@{\_\-\_\-getopt\_\-initialized}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf \_\-\_\-getopt\_\-initialized}}\label{TestMasterSlave_2getopt_8c_28286be757527aeb1db951b5da9aeec1}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!first_nonopt@{first\_\-nonopt}}
nico@207: \index{first_nonopt@{first\_\-nonopt}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf first\_\-nonopt}\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_7b0f4f3bfbee147113f282427ce933ed}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!last_nonopt@{last\_\-nonopt}}
nico@207: \index{last_nonopt@{last\_\-nonopt}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf last\_\-nonopt}\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_580f2c2acf35dad51ca18b427212bf15}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!nextchar@{nextchar}}
nico@207: \index{nextchar@{nextchar}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ {\bf nextchar}\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_47a40a4c365dae45f94751ad32aab530}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!optarg@{optarg}}
nico@207: \index{optarg@{optarg}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ {\bf optarg}}\label{TestMasterSlave_2getopt_8c_db50a0eab9fed92fc3bfc7dfa4f2c410}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!opterr@{opterr}}
nico@207: \index{opterr@{opterr}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf opterr} = 1}\label{TestMasterSlave_2getopt_8c_e30f05ee1e2e5652f174a35c7875d25e}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!optind@{optind}}
nico@207: \index{optind@{optind}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf optind} = 1}\label{TestMasterSlave_2getopt_8c_d5e1c16213bbee2d5e8cc363309f418c}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!optopt@{optopt}}
nico@207: \index{optopt@{optopt}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf optopt} = '?'}\label{TestMasterSlave_2getopt_8c_475b8db98445da73e5f62a1ef6324b95}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!ordering@{ordering}}
nico@207: \index{ordering@{ordering}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}enum \{ ... \}   {\bf ordering}\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_d6e641c007a3362710ee1c7e22c02e8c}
nico@207: 
nico@207: 
nico@207: \index{TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}!posixly_correct@{posixly\_\-correct}}
nico@207: \index{posixly_correct@{posixly\_\-correct}!TestMasterSlave/getopt.c@{Test\-Master\-Slave/getopt.c}}
nico@207: \subsubsection{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ {\bf posixly\_\-correct}\hspace{0.3cm}{\tt  [static]}}\label{TestMasterSlave_2getopt_8c_d0ccb64bbd4defe7a57dbad2045ddd14}
nico@207: 
nico@207: 




