92 lines
6.1 KiB
HTML
92 lines
6.1 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
|
|
<title>/home/James/ZEngine-dev/include/ZE_ZConfigFile.h Source File</title>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css">
|
|
</head><body>
|
|
<!-- Generated by Doxygen 1.3-rc1 -->
|
|
<center>
|
|
<a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="namespaces.html">Namespace List</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="namespacemembers.html">Namespace Members</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> </center>
|
|
<hr><h1>/home/James/ZEngine-dev/include/ZE_ZConfigFile.h</h1><a href="ZE__ZConfigFile_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <span class="comment">/*******************************************************************************</span>
|
|
00002 <span class="comment"> This file is Part of the ZEngine Library for SDL Game Development.</span>
|
|
00003 <span class="comment"> Copyright (C) 2002 ConceptOfZero.net</span>
|
|
00004 <span class="comment"></span>
|
|
00005 <span class="comment"> Licensed under the BSD License, see licensing.txt.</span>
|
|
00006 <span class="comment"></span>
|
|
00007 <span class="comment"> The maintainer of this library is James Turk (jturk@conceptofzero.net) </span>
|
|
00008 <span class="comment"> and the home of this Library is http://www.conceptofzero.net/</span>
|
|
00009 <span class="comment">*******************************************************************************/</span>
|
|
00010
|
|
00025 <span class="preprocessor">#ifndef __ze_zconfigfile_h__</span>
|
|
00026 <span class="preprocessor"></span><span class="preprocessor">#define __ze_zconfigfile_h__</span>
|
|
00027 <span class="preprocessor"></span>
|
|
00028 <span class="preprocessor">#include "<a class="code" href="ZE__ZObject_8h.html">ZE_ZObject.h</a>"</span> <span class="comment">//included even though ZCF isn't derived (to obtain all other needed headers)</span>
|
|
00029
|
|
00030 <span class="keyword">namespace </span>ZE
|
|
00031 {
|
|
00032
|
|
00038 <span class="keyword">class </span>ZConfigFile : <span class="keyword">public</span> ZObject
|
|
00039 {
|
|
00040 <span class="keyword">private</span>:
|
|
00041
|
|
00042 <span class="comment">/*Private Types*/</span>
|
|
00043 <span class="keyword">class </span>ZCF_Variable
|
|
00044 {
|
|
00045 <span class="keyword">public</span>:
|
|
00046 string var;
|
|
00047 string val;
|
|
00048 };
|
|
00049 <span class="keyword">class </span>ZCF_Section
|
|
00050 {
|
|
00051 <span class="keyword">public</span>:
|
|
00052 string section;
|
|
00053 list<ZCF_Variable> varList;
|
|
00054 };
|
|
00055
|
|
00057 list<ZCF_Section> <a class="code" href="classZE_1_1ZConfigFile.html#o0">mFileLayout</a>;
|
|
00058
|
|
00060 string <a class="code" href="classZE_1_1ZConfigFile.html#o1">mFilename</a>;
|
|
00061
|
|
00069 string <a class="code" href="classZE_1_1ZConfigFile.html#c0">CleanString</a>(string str);
|
|
00070
|
|
00071 <span class="keywordtype">bool</span> Exists(string sec);
|
|
00072 <span class="keywordtype">bool</span> Exists(string sec, string var);
|
|
00073 <span class="keywordtype">void</span> SetVariable(string sec, string var, string val);
|
|
00074 string GetVariable(string sec, string var, string defVal);
|
|
00075
|
|
00076 <span class="keyword">public</span>:
|
|
00077
|
|
00083 <a class="code" href="classZE_1_1ZConfigFile.html#a0">ZConfigFile</a>();
|
|
00084
|
|
00091 <a class="code" href="classZE_1_1ZConfigFile.html#a0">ZConfigFile</a>(string filename);
|
|
00092
|
|
00098 <a class="code" href="classZE_1_1ZConfigFile.html#a2">~ZConfigFile</a>();
|
|
00099
|
|
00106 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZConfigFile.html#a3">Process</a>(string filename);
|
|
00107
|
|
00117 <span class="keywordtype">int</span> <a class="code" href="classZE_1_1ZConfigFile.html#a4">GetInt</a>(string section, string var, <span class="keywordtype">int</span> defVal);
|
|
00118
|
|
00129 <span class="keywordtype">bool</span> <a class="code" href="classZE_1_1ZConfigFile.html#a5">GetBool</a>(string section, string var, <span class="keywordtype">bool</span> defVal);
|
|
00130
|
|
00140 string <a class="code" href="classZE_1_1ZConfigFile.html#a6">GetString</a>(string section, string var, string defVal);
|
|
00141
|
|
00151 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZConfigFile.html#a7">SetInt</a>(string section, string var, <span class="keywordtype">int</span> val);
|
|
00152
|
|
00162 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZConfigFile.html#a8">SetBool</a>(string section, string var, <span class="keywordtype">bool</span> val);
|
|
00163
|
|
00173 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZConfigFile.html#a9">SetString</a>(string section, string var, string val);
|
|
00174
|
|
00180 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZConfigFile.html#a10">Flush</a>();
|
|
00181
|
|
00187 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZConfigFile.html#a11">Close</a>();
|
|
00188 };
|
|
00189
|
|
00190 }
|
|
00191
|
|
00192 <span class="preprocessor">#endif //__ze_zconfigfile_h__</span>
|
|
</pre></div><hr><address style="align: right;"><small>Generated on Wed Nov 20 01:18:05 2002 for ZEngine by
|
|
<a href="http://www.doxygen.org/index.html">
|
|
<img src="doxygen.png" alt="doxygen" align="middle" border=0
|
|
width=110 height=53></a>1.3-rc1 </small></address>
|
|
</body>
|
|
</html>
|