<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>pcsc-lite: parser.h File Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.6.2-20100208 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> <li><a href="dirs.html"><span>Directories</span></a></li> </ul> </div> <div class="tabs"> <ul> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>Globals</span></a></li> </ul> </div> <div class="navpath"><a class="el" href="dir_c68a5dfdca54003c765e303a18006edb.html">src</a> </div> </div> <div class="contents"> <h1>parser.h File Reference</h1> <p>Reads lexical config files and updates database. <a href="#_details">More...</a></p> <div class="dynheader"> This graph shows which files directly or indirectly include this file:</div> <div class="dynsection"> </div> <p><a href="parser_8h_source.html">Go to the source code of this file.</a></p> <table border="0" cellpadding="0" cellspacing="0"> <tr><td colspan="2"><h2>Defines</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ada87429c8994e8d7a26e492588457e03"></a><!-- doxytag: member="parser.h::TOKEN_MAX_KEY_SIZE" ref="ada87429c8994e8d7a26e492588457e03" args="" --> #define </td><td class="memItemRight" valign="bottom"><b>TOKEN_MAX_KEY_SIZE</b> 200</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9345481cb2851102017076d4c8ce61bc"></a><!-- doxytag: member="parser.h::TOKEN_MAX_VALUE_SIZE" ref="a9345481cb2851102017076d4c8ce61bc" args="" --> #define </td><td class="memItemRight" valign="bottom"><b>TOKEN_MAX_VALUE_SIZE</b> 200</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a868ae193fadc097d1bea8e3c2f6c9161"></a><!-- doxytag: member="parser.h::TOKEN_TYPE_KEY" ref="a868ae193fadc097d1bea8e3c2f6c9161" args="" --> #define </td><td class="memItemRight" valign="bottom"><b>TOKEN_TYPE_KEY</b> 1</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="af6e21f6eb6cf1982ac1e3ee5462b917f"></a><!-- doxytag: member="parser.h::TOKEN_TYPE_STRING" ref="af6e21f6eb6cf1982ac1e3ee5462b917f" args="" --> #define </td><td class="memItemRight" valign="bottom"><b>TOKEN_TYPE_STRING</b> 2</td></tr> <tr><td colspan="2"><h2>Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="parser_8h.html#a9d31e57b21258fb2029f8e8fb5e1efbe">LTPBundleFindValueWithKey</a> (const char *fileName, const char *tokenKey, char *tokenValue, int tokenIndice)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Find a key in a configuration file. <a href="#a9d31e57b21258fb2029f8e8fb5e1efbe"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="parser_8h.html#a5814a199a4d36e451c0fc309b9934b90">LTPBundleFindOptionalValueWithKey</a> (const char *fileName, const char *tokenKey, char *tokenValue, int tokenIndice)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Find an optional key in a configuration file No error is logged if the key is not found. <a href="#a5814a199a4d36e451c0fc309b9934b90"></a><br/></td></tr> </table> <hr/><a name="_details"></a><h2>Detailed Description</h2> <p>Reads lexical config files and updates database. </p> <p>Definition in file <a class="el" href="parser_8h_source.html">parser.h</a>.</p> <hr/><h2>Function Documentation</h2> <a class="anchor" id="a5814a199a4d36e451c0fc309b9934b90"></a><!-- doxytag: member="parser.h::LTPBundleFindOptionalValueWithKey" ref="a5814a199a4d36e451c0fc309b9934b90" args="(const char *fileName, const char *tokenKey, char *tokenValue, int tokenIndice)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int LTPBundleFindOptionalValueWithKey </td> <td>(</td> <td class="paramtype">const char * </td> <td class="paramname"> <em>fileName</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const char * </td> <td class="paramname"> <em>tokenKey</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">char * </td> <td class="paramname"> <em>tokenValue</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>tokenIndice</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Find an optional key in a configuration file No error is logged if the key is not found. </p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>fileName</em> </td><td>file name </td></tr> <tr><td valign="top"></td><td valign="top"><em>tokenKey</em> </td><td>key value </td></tr> <tr><td valign="top"><tt>[out]</tt> </td><td valign="top"><em>tokenValue</em> </td><td>token value (if key found) </td></tr> <tr><td valign="top"></td><td valign="top"><em>tokenIndice</em> </td><td>indice of the desired key </td></tr> </table> </dd> </dl> <dl><dt><b>Return values:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>-1</em> </td><td>configuration file not found </td></tr> <tr><td valign="top"></td><td valign="top"><em>0</em> </td><td>OK </td></tr> <tr><td valign="top"></td><td valign="top"><em>1</em> </td><td>key not found </td></tr> </table> </dd> </dl> <p>Definition at line <a class="el" href="tokenparser_8c_source.html#l01873">1873</a> of file <a class="el" href="tokenparser_8c_source.html">tokenparser.c</a>.</p> <p>Referenced by <a class="el" href="tokenparser_8c_source.html#l01916">LTPBundleFindValueWithKey()</a>.</p> </div> </div> <a class="anchor" id="a9d31e57b21258fb2029f8e8fb5e1efbe"></a><!-- doxytag: member="parser.h::LTPBundleFindValueWithKey" ref="a9d31e57b21258fb2029f8e8fb5e1efbe" args="(const char *fileName, const char *tokenKey, char *tokenValue, int tokenIndice)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int LTPBundleFindValueWithKey </td> <td>(</td> <td class="paramtype">const char * </td> <td class="paramname"> <em>fileName</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const char * </td> <td class="paramname"> <em>tokenKey</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">char * </td> <td class="paramname"> <em>tokenValue</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>tokenIndice</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Find a key in a configuration file. </p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>fileName</em> </td><td>file name </td></tr> <tr><td valign="top"></td><td valign="top"><em>tokenKey</em> </td><td>key value </td></tr> <tr><td valign="top"><tt>[out]</tt> </td><td valign="top"><em>tokenValue</em> </td><td>token value (if key found) </td></tr> <tr><td valign="top"></td><td valign="top"><em>tokenIndice</em> </td><td>indice of the desired key </td></tr> </table> </dd> </dl> <dl><dt><b>Return values:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>-1</em> </td><td>configuration file not found </td></tr> <tr><td valign="top"></td><td valign="top"><em>0</em> </td><td>OK </td></tr> <tr><td valign="top"></td><td valign="top"><em>1</em> </td><td>key not found </td></tr> </table> </dd> </dl> <p>Definition at line <a class="el" href="tokenparser_8c_source.html#l01916">1916</a> of file <a class="el" href="tokenparser_8c_source.html">tokenparser.c</a>.</p> <p>References <a class="el" href="tokenparser_8c_source.html#l01873">LTPBundleFindOptionalValueWithKey()</a>.</p> <p><div class="dynheader"> Here is the call graph for this function:</div> <div class="dynsection"> </div> </p> </div> </div> </div> <hr class="footer"/><address style="text-align: right;"><small>Generated by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.2-20100208 </small></address> </body> </html>