diff options
Diffstat (limited to 'docs/doxygen/nel/classNLMISC_1_1CPath.html')
-rw-r--r-- | docs/doxygen/nel/classNLMISC_1_1CPath.html | 1202 |
1 files changed, 1202 insertions, 0 deletions
diff --git a/docs/doxygen/nel/classNLMISC_1_1CPath.html b/docs/doxygen/nel/classNLMISC_1_1CPath.html new file mode 100644 index 00000000..d69ca3cb --- /dev/null +++ b/docs/doxygen/nel/classNLMISC_1_1CPath.html @@ -0,0 +1,1202 @@ +<!doctype html public "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"> +<HTML> +<HEAD> + <TITLE>nevrax.org : docs</TITLE> + <LINK REL=stylesheet TYPE="text/css" HREF="http://www.nevrax.org/inc/css/nevrax.css"> + <link href="doxygen.css" rel="stylesheet" type="text/css"> +</HEAD> +<BODY MARGINHEIGHT="0" MARGINWIDTH="0"> + +<!-- uplinks --> +<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0> + <TR> + <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD WIDTH=140 BGCOLOR=#dddddd><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD><IMG width=6 height=14 SRC="http://www.nevrax.org/inc/img/reddots.gif" ALT="#" VSPACE=2 HSPACE=2 BORDER=0 ></TD><TD VALIGN=middle> <A CLASS=uplinks HREF=http://www.nevrax.org><b>Home</B></FONT></A> </TD> + <TD><IMG width=6 height=14 SRC="http://www.nevrax.org/inc/img/reddots.gif" ALT="#" VSPACE=2 HSPACE=2 BORDER=0 ></TD><TD VALIGN=middle> <A CLASS=uplinks HREF=http://www.nevrax.com><b>nevrax.com</B></FONT></A> </TD> + </TR> +</TABLE> + +<!-- banner Nevrax --> +<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%> + <TR><TD BGCOLOR="#000000" BACKGROUND="http://www.nevrax.org/inc/img/black_banner.jpg"><A HREF="http://www.nevrax.org"><IMG SRC="http://www.nevrax.org/inc/img/nevrax.gif" WIDTH="170" HEIGHT="45" BORDER=0 ALT="Nevrax" ></A></TD></TR> +</TABLE> + +<!-- main table --> +<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 height=100%> + <TR> + <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="10" BORDER=0 ALT=""></TD> + <TD WIDTH=140 BGCOLOR=#dddddd VALIGN=TOP ALIGN=middle><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="10" BORDER=0 ALT=""> + + <!------ Begin Box ------> + <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=black><TR><TD><TABLE border=0 cellspacing=2 cellpadding=0 width=120><tr><TD ALIGN=middle bgcolor=black> + <FONT COLOR=white FACE="sans-serif"><B>Nevrax.org</B></FONT></TD></TR><tr><td colspan=2 bgcolor=#FFFFFF> + <TABLE cellspacing=0 cellpadding=1 border=0> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/news/" TITLE="Rubrique news"><img width=13 height=15 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-news.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/news/" TITLE="News">News</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/mail/" TITLE="Rubrique mail"><img width=15 height=11 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-mail.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/mail/" TITLE="Mailing list archive">Mailing-list</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/docs/" TITLE="Rubrique docs"><img width=14 height=16 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-docs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/docs/" TITLE="Documentation">Documentation</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/cvs/" TITLE="Rubrique cvs"><img width=13 height=17 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-cvs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/cvs/" TITLE="CVS Web">CVS</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/bugs/" TITLE="Rubrique bugs"><img width=20 height=16 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-bugs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/bugs/" TITLE="Bugtracking">Bugs</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/GPL.php3" TITLE="Rubrique license"><img width=18 height=12 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-gpl.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/GPL.php3" TITLE="License">License</a></td></tr> + </TABLE> + </TD></TR></TABLE></TD></TR></TABLE> + <!------ End Box ------> + + </TD> + <TD WIDTH=15><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD ALIGN=left valign=top><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="10" BORDER=0 ALT=""> + +<!-- title --> +<TABLE background="http://www.nevrax.org/inc/img/redline.gif" CELLSPACING=0 CELLPADDING=0 BORDER=0 width=100%><tr><td> +<A HREF="http://www.nevrax.org/docs/"><img src="http://www.nevrax.org/inc/img/t_docs.gif" ALT="Docs" HEIGHT=20 BORDER=0></A> +</td><td><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="1" HEIGHT="1" BORDER=0 ALT=""> +</td></tr></table> + + +<!-- block --> +<TABLE bgcolor="#dddddd" CELLSPACING=0 CELLPADDING=0 BORDER=0 width=100%><tr><td width=1% valign=middle><img width=6 height=14 hspace=2 vspace=2 src="http://www.nevrax.org/inc/img/reddots.gif"></TD> + <TD><B>Documentation</B></TD> + <TD ALIGN=RIGHT> </td> +</tr></table> +<!-- Generated by Doxygen 1.2.14 --> +<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="classes.html">Alphabetical List</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> <a class="qindex" href="pages.html">Related Pages</a> <a class="qindexRef" doxygen="_cgi:http://www.nevrax.org/cgi-bin/nel-search.cgi" href="http://www.nevrax.org/cgi-bin/nel-search.cgi">Search</a> </center> +<hr><h1>NLMISC::CPath Class Reference</h1>Utility class for searching files in differents paths. +<a href="#_details">More...</a> +<p> +<code>#include <<a class="el" href="path_8h-source.html">path.h</a>></code> +<p> +<a href="classNLMISC_1_1CPath-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0> +<tr><td colspan=2><br><h2>Static Public Methods</h2></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d0">addSearchPath</a> (const std::string &path, bool recurse, bool alternative)</td></tr> +<tr><td> </td><td><font size=-1><em>Adds a search path.</em> <a href="#d0">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d1">addSearchPath</a> (const std::string &path)</td></tr> +<tr><td> </td><td><font size=-1><em>Used only for compatibility with the old <a class="el" href="classNLMISC_1_1CPath.html">CPath</a>.</em> <a href="#d1">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d2">addSearchFile</a> (const std::string &<a class="el" href="cf__lexical_8cpp.html#a95">file</a>, bool remap=false, const std::string &virtual_ext="")</td></tr> +<tr><td> </td><td><font size=-1><em>Same as AddSearchPath but with a file "c:/autoexec.bat" this file only will included.</em> <a href="#d2">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d3">addSearchListFile</a> (const std::string &filename, bool recurse, bool alternative)</td></tr> +<tr><td> </td><td><font size=-1><em>Same as AddSearchPath but with a path file "c:/test.pth" all files name contain in this file will be included (the extention is used to know that it's a path file).</em> <a href="#d3">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d4">addSearchBigFile</a> (const std::string &filename, bool recurse, bool alternative)</td></tr> +<tr><td> </td><td><font size=-1><em>Same as AddSearchPath but with a big file "c:/test.nbf" all files name contain in the big file will be included (the extention (Nel Big File) is used to know that it's a big file).</em> <a href="#d4">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d5">removeAllAlternativeSearchPath</a> ()</td></tr> +<tr><td> </td><td><font size=-1><em>Remove all search path contains in the alternative directories.</em> <a href="#d5">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>std::string </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d6">lookup</a> (const std::string &filename, bool throwException=true, bool displayWarning=true, bool lookupInLocalDirectory=true)</td></tr> +<tr><td> </td><td><font size=-1><em>Returns the long name (path + filename) for the specified file.</em> <a href="#d6">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>bool </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d7">exists</a> (const std::string &filename)</td></tr> +<tr><td> </td><td><font size=-1><em>Return if a file is present in the lookup map.</em> <a href="#d7">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d8">clearMap</a> ()</td></tr> +<tr><td> </td><td><font size=-1><em>Clears the map that contains all cached files (Use this function to take into account new files).</em> <a href="#d8">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d9">remapExtension</a> (const std::string &ext1, const std::string &ext2, bool substitute)</td></tr> +<tr><td> </td><td><font size=-1><em>Add a remapping function to allow file extension substitution.</em> <a href="#d9">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d10">display</a> ()</td></tr> +<tr><td nowrap align=right valign=top>std::string </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d11">standardizePath</a> (const std::string &path, bool addFinalSlash=true)</td></tr> +<tr><td> </td><td><font size=-1><em>Take a path and put it in the portable format and add a terminated / if needed ie: "C:\Game/dir1" will become "C:/Game/dir1/" or "C:/Game/dir1" if addFinalSlash is false.</em> <a href="#d11">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>std::string </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d12">standardizeDosPath</a> (const std::string &path)</td></tr> +<tr><td> </td><td><font size=-1><em>Remplace / with \ for fucking dos process.</em> <a href="#d12">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d13">getPathContent</a> (const std::string &path, bool recurse, bool wantDir, bool wantFile, std::vector< std::string > &result)</td></tr> +<tr><td> </td><td><font size=-1><em>List all files in a directory.</em> <a href="#d13">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>std::string </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d14">getFullPath</a> (const std::string &path, bool addFinalSlash=true)</td></tr> +<tr><td> </td><td><font size=-1><em>Get the full path based on a file/path and the current directory.</em> <a href="#d14">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>std::string </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d15">getCurrentPath</a> ()</td></tr> +<tr><td> </td><td><font size=-1><em>Returns the current path of the applicated.</em> <a href="#d15">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#d16">getFileList</a> (const std::string &extension, std::vector< std::string > &filenames)</td></tr> +<tr><td> </td><td><font size=-1><em>Create a list of file having the requested extension.</em> <a href="#d16">More...</a><em></em></font><br><br></td></tr> +<tr><td colspan=2><br><h2>Private Methods</h2></td></tr> +<tr><td nowrap align=right valign=top><a class="el" href="memory__common_8h.html#a14">sint</a> </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#c0">findExtension</a> (const std::string &ext1, const std::string &ext2)</td></tr> +<tr><td colspan=2><br><h2>Static Private Methods</h2></td></tr> +<tr><td nowrap align=right valign=top>CPath * </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#f0">getInstance</a> ()</td></tr> +<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#f1">insertFileInMap</a> (const std::string &filename, const std::string &filepath, bool remap, const std::string &extension)</td></tr> +<tr><td colspan=2><br><h2>Private Attributes</h2></td></tr> +<tr><td nowrap align=right valign=top>std::vector< std::string > </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#o0">_AlternativePaths</a></td></tr> +<tr><td nowrap align=right valign=top>std::map< std::string, <a class="el" href="structNLMISC_1_1CPath_1_1CFileEntry.html">CFileEntry</a> > </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#o1">_Files</a></td></tr> +<tr><td> </td><td><font size=-1><em>first is the filename, second the full path for the filename.</em> <a href="#o1">More...</a><em></em></font><br><br></td></tr> +<tr><td nowrap align=right valign=top>std::vector< std::pair< std::string,<br> + std::string > > </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#o2">_Extensions</a></td></tr> +<tr><td> </td><td><font size=-1><em>first ext1, second ext2 (ext1 could remplace ext2).</em> <a href="#o2">More...</a><em></em></font><br><br></td></tr> +<tr><td colspan=2><br><h2>Static Private Attributes</h2></td></tr> +<tr><td nowrap align=right valign=top>CPath * </td><td valign=bottom><a class="el" href="classNLMISC_1_1CPath.html#r0">_Instance</a> = NULL</td></tr> +</table> +<hr><a name="_details"></a><h2>Detailed Description</h2> +Utility class for searching files in differents paths. +<p> +<dl compact><dt><b> +Warning: </b><dd> +<a class="el" href="classNLMISC_1_1CPath.html#d0">addSearchPath</a>(), <a class="el" href="classNLMISC_1_1CPath.html#d8">clearMap</a>() and <a class="el" href="classNLMISC_1_1CPath.html#d9">remapExtension</a>() are not reentrant. <dd> +all path and files are *case sensitive* on linux. </dl><dl compact><dt><b> +Author: </b><dd> +Vianney Lecroart , Nevrax France </dl><dl compact><dt><b> +Date: </b><dd> +2001 </dl> +<p> + +<p> +Definition at line <a class="el" href="path_8h-source.html#l00054">54</a> of file <a class="el" href="path_8h-source.html">path.h</a>.<hr><h2>Member Function Documentation</h2> +<a name="d4" doxytag="NLMISC::CPath::addSearchBigFile"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::addSearchBigFile </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>filename</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>recurse</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>alternative</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Same as AddSearchPath but with a big file "c:/test.nbf" all files name contain in the big file will be included (the extention (Nel Big File) is used to know that it's a big file). +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00800">800</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="big__file_8h-source.html#l00042">NLMISC::BF_ALWAYS_OPENED</a>, <a class="el" href="big__file_8h-source.html#l00043">NLMISC::BF_CACHE_FILE_ON_OPEN</a>, <a class="el" href="path_8cpp-source.html#l00881">insertFileInMap</a>, <a class="el" href="debug_8h-source.html#l00114">nlwarning</a>, and <a class="el" href="common_8cpp-source.html#l00426">NLMISC::strlwr</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00708">addSearchFile</a>. </td> + </tr> +</table> +<a name="d2" doxytag="NLMISC::CPath::addSearchFile"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::addSearchFile </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>file</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>remap</em> = false, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>const std::string & </td> + <td class="mdname" nowrap> <em>virtual_ext</em> = ""</td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Same as AddSearchPath but with a file "c:/autoexec.bat" this file only will included. +<p> +wildwards *doesn't* work +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00708">708</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00800">addSearchBigFile</a>, <a class="el" href="cf__lexical_8cpp-source.html#l02654">file</a>, <a class="el" href="path_8cpp-source.html#l00881">insertFileInMap</a>, <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>, <a class="el" href="debug_8h-source.html#l00114">nlwarning</a>, <a class="el" href="path_8cpp-source.html#l00296">standardizePath</a>, and <a class="el" href="common_8cpp-source.html#l00426">NLMISC::strlwr</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00623">addSearchPath</a>. </td> + </tr> +</table> +<a name="d3" doxytag="NLMISC::CPath::addSearchListFile"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::addSearchListFile </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>filename</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>recurse</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>alternative</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Same as AddSearchPath but with a path file "c:/test.pth" all files name contain in this file will be included (the extention is used to know that it's a path file). +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00772">772</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="debug_8h-source.html#l00114">nlwarning</a>. </td> + </tr> +</table> +<a name="d1" doxytag="NLMISC::CPath::addSearchPath"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::addSearchPath </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname1" valign="top" nowrap> <em>path</em> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [inline, static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Used only for compatibility with the old <a class="el" href="classNLMISC_1_1CPath.html">CPath</a>. +<p> +In this case, we don't use the map to have the same behavior as the old <a class="el" href="classNLMISC_1_1CPath.html">CPath</a> +<p> +Definition at line <a class="el" href="path_8h-source.html#l00076">76</a> of file <a class="el" href="path_8h-source.html">path.h</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00623">addSearchPath</a>. </td> + </tr> +</table> +<a name="d0" doxytag="NLMISC::CPath::addSearchPath"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::addSearchPath </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>path</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>recurse</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>alternative</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Adds a search path. +<p> +The path is a directory "c:/temp" all files in the directory will be included (and recursively if asked) +<p> +Alternative directories are not precached (instead of non Alternative files) and will used when a file is not found in the standard directories. For example, local data will be in the cached directories and server repository files will be in the Alternative files. If a new file is not found in the local data, we'll try to find it on the repositrory. +<p> +When Alternative is false, all added file names must be uniq or a warning will be display. In the Alternative directories, it could have more than one file with the same name. +<p> +<dl compact><dt><b> +Warning: </b><dd> +the path you provide is case sensitive, you must be sure that the path name is exactly the same</dl><dl compact><dt><b> +Parameters: </b><dd> +<table border=0 cellspacing=2 cellpadding=0> +<tr><td valign=top><em>path</em> </td><td> +the path name. The separator for directories could be '/' or '\' (bit '\' will be translate into '/' in the function). </td></tr> +<tr><td valign=top><em>recurse</em> </td><td> +true if you want the function recurse in sub-directories. </td></tr> +<tr><td valign=top><em>Alternative</em> </td><td> +true if you want to add the path in the Alternative directories. </td></tr> +</table> +</dl> +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00623">623</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00708">addSearchFile</a>, <a class="el" href="path_8cpp-source.html#l00623">addSearchPath</a>, <a class="el" href="path_8cpp-source.html#l00523">getPathContent</a>, <a class="el" href="hierarchical__timer_8h-source.html#l00056">H_AUTO_INST</a>, <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>, <a class="el" href="debug_8h-source.html#l00094">nlinfo</a>, <a class="el" href="debug_8h-source.html#l00114">nlwarning</a>, and <a class="el" href="path_8cpp-source.html#l00296">standardizePath</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00623">addSearchPath</a>. </td> + </tr> +</table> +<a name="d8" doxytag="NLMISC::CPath::clearMap"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::clearMap </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Clears the map that contains all cached files (Use this function to take into account new files). +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00107">107</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>. </td> + </tr> +</table> +<a name="d10" doxytag="NLMISC::CPath::display"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::display </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00910">910</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="debug_8h-source.html#l00094">nlinfo</a>. </td> + </tr> +</table> +<a name="d7" doxytag="NLMISC::CPath::exists"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> bool NLMISC::CPath::exists </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname1" valign="top" nowrap> <em>filename</em> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Return if a file is present in the lookup map. +<p> +The function changes filename into lower case and removes ended spaces before searching. +<p> +<dl compact><dt><b> +Warning: </b><dd> +This function checks *only* in the map, not in local dir or alternative dir</dl><dl compact><dt><b> +Parameters: </b><dd> +<table border=0 cellspacing=2 cellpadding=0> +<tr><td valign=top><em>filename</em> </td><td> +the file name you are seeking. (ex: "test.txt") </td></tr> +<tr><td valign=top><em>lookupInLocalDirectory</em> </td><td> +if true, the <a class="el" href="classNLMISC_1_1CPath.html#d6">lookup</a>() will first try to open the file without path. </td></tr> +</table> +</dl><dl compact><dt><b> +Returns: </b><dd> +true if the filename exists in the map used by lookup to know where the file is, false otherwise </dl> +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00274">274</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="common_8cpp-source.html#l00426">NLMISC::strlwr</a>. </td> + </tr> +</table> +<a name="c0" doxytag="NLMISC::CPath::findExtension"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="memory__common_8h.html#a14">sint</a> NLMISC::CPath::findExtension </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>ext1</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>const std::string & </td> + <td class="mdname" nowrap> <em>ext2</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00114">114</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. </td> + </tr> +</table> +<a name="d15" doxytag="NLMISC::CPath::getCurrentPath"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> std::string NLMISC::CPath::getCurrentPath </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Returns the current path of the applicated. +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00349">349</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00360">getFullPath</a>. </td> + </tr> +</table> +<a name="d16" doxytag="NLMISC::CPath::getFileList"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::getFileList </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>extension</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>std::vector< std::string > & </td> + <td class="mdname" nowrap> <em>filenames</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Create a list of file having the requested extension. +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00085">85</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8h-source.html#l00198">_Files</a>, and <a class="el" href="path_8cpp-source.html#l00098">getInstance</a>. +<p> +Referenced by <a class="el" href="load__form_8h-source.html#l00314">loadForm</a>. </td> + </tr> +</table> +<a name="d14" doxytag="NLMISC::CPath::getFullPath"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> std::string NLMISC::CPath::getFullPath </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>path</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>addFinalSlash</em> = true</td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Get the full path based on a file/path and the current directory. +<p> +Example, imagine that the current path is c:\temp and toto is a directory getFullPath ("toto") returns "c:/temp/toto/" getFullPath ("../toto") returns "c:/temp/../toto/" getFullPath ("d:\dir\toto") returns "d:/dir/toto/" getFullPath ("\toto") returns "c:/toto/" getFullPath ("") returns "c:/temp/"<dl compact><dt><b> +Parameters: </b><dd> +<table border=0 cellspacing=2 cellpadding=0> +<tr><td valign=top><em>path</em> </td><td> +the path </td></tr> +</table> +</dl><dl compact><dt><b> +Returns: </b><dd> +the full path </dl> +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00360">360</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00349">getCurrentPath</a>, and <a class="el" href="path_8cpp-source.html#l00296">standardizePath</a>. </td> + </tr> +</table> +<a name="f0" doxytag="NLMISC::CPath::getInstance"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> CPath * NLMISC::CPath::getInstance </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [static, private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00098">98</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00078">_Instance</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00085">getFileList</a>. </td> + </tr> +</table> +<a name="d13" doxytag="NLMISC::CPath::getPathContent"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::getPathContent </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>path</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>recurse</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>wantDir</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>wantFile</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>std::vector< std::string > & </td> + <td class="mdname" nowrap> <em>result</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +List all files in a directory. +<p> +<dl compact><dt><b> +Parameters: </b><dd> +<table border=0 cellspacing=2 cellpadding=0> +<tr><td valign=top><em>path</em> </td><td> +path where files are scanned (MUST NOT BE EMPTY) </td></tr> +<tr><td valign=top><em>recurse</em> </td><td> +true if want to recurs directories </td></tr> +<tr><td valign=top><em>wantDir</em> </td><td> +true if want to add directorires in result </td></tr> +<tr><td valign=top><em>wantFile</em> </td><td> +true if want to add files in result </td></tr> +<tr><td valign=top><em>result</em> </td><td> +list of string where directories/files names are added. </td></tr> +</table> +</dl> +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00523">523</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00481">NLMISC::BasePathgetPathContent</a>, <a class="el" href="path_8cpp-source.html#l00513">NLMISC::getname</a>, <a class="el" href="path_8cpp-source.html#l00484">NLMISC::isdirectory</a>, <a class="el" href="path_8cpp-source.html#l00499">NLMISC::isfile</a>, <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>, and <a class="el" href="path_8cpp-source.html#l00296">standardizePath</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00623">addSearchPath</a>, and <a class="el" href="animation__set_8cpp-source.html#l00155">NL3D::CAnimationSet::loadFromFiles</a>. </td> + </tr> +</table> +<a name="f1" doxytag="NLMISC::CPath::insertFileInMap"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::insertFileInMap </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>filename</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>const std::string & </td> + <td class="mdname" nowrap> <em>filepath</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>remap</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>const std::string & </td> + <td class="mdname" nowrap> <em>extension</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static, private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00881">881</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>, <a class="el" href="debug_8h-source.html#l00094">nlinfo</a>, <a class="el" href="debug_8h-source.html#l00114">nlwarning</a>, and <a class="el" href="common_8cpp-source.html#l00426">NLMISC::strlwr</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00800">addSearchBigFile</a>, <a class="el" href="path_8cpp-source.html#l00708">addSearchFile</a>, and <a class="el" href="path_8cpp-source.html#l00127">remapExtension</a>. </td> + </tr> +</table> +<a name="d6" doxytag="NLMISC::CPath::lookup"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> string NLMISC::CPath::lookup </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>filename</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>throwException</em> = true, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>displayWarning</em> = true, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>lookupInLocalDirectory</em> = true</td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Returns the long name (path + filename) for the specified file. +<p> +The directory separator is always '/'. First, the <a class="el" href="classNLMISC_1_1CPath.html#d6">lookup</a>() lookups in standard directories (Alternative=false). If not found, it lookups in the Alternative directories. If not found the <a class="el" href="classNLMISC_1_1CPath.html#d6">lookup</a>() returns empty string "" (and generate an exception if throwException is true) +<p> +The filename is not case sensitive so if the real filename is "FooBAR.Jpg" and you call lookup("fOOBar.jPg"), it'll return the real filename "FooBAR.Jpg"<dl compact><dt><b> +Parameters: </b><dd> +<table border=0 cellspacing=2 cellpadding=0> +<tr><td valign=top><em>filename</em> </td><td> +the file name you are seeking. (ex: "test.txt") </td></tr> +<tr><td valign=top><em>throwException</em> </td><td> +used for backward compatibility, set to true to generate an <a class="el" href="structNLMISC_1_1EPathNotFound.html">EPathNotFound</a>. </td></tr> +<tr><td valign=top><em>displayWarning</em> </td><td> +set to false if you don't want the function displays a warning if the file is not found </td></tr> +<tr><td valign=top><em>lookupInLocalDirectory</em> </td><td> +if true, the <a class="el" href="classNLMISC_1_1CPath.html#d6">lookup</a>() will first try to open the file without path. </td></tr> +</table> +</dl><dl compact><dt><b> +Returns: </b><dd> +empty string if file is not found or the full path + file name (ex: "c:/temp/test.txt"); </dl> +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00201">201</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>, <a class="el" href="debug_8h-source.html#l00114">nlwarning</a>, <a class="el" href="driver__opengl__extension__def_8h-source.html#l00673">s</a>, and <a class="el" href="common_8cpp-source.html#l00426">NLMISC::strlwr</a>. +<p> +Referenced by <a class="el" href="animation__set__user_8h-source.html#l00095">NL3D::CAnimationSetUser::addAnimation</a>, <a class="el" href="animation__set__user_8h-source.html#l00139">NL3D::CAnimationSetUser::addSkeletonWeight</a>, <a class="el" href="animation_8cpp-source.html#l00259">NL3D::UAnimation::createAnimation</a>, and <a class="el" href="load__form_8h-source.html#l00113">loadForm</a>. </td> + </tr> +</table> +<a name="d9" doxytag="NLMISC::CPath::remapExtension"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::remapExtension </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>ext1</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>const std::string & </td> + <td class="mdname" nowrap> <em>ext2</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>substitute</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Add a remapping function to allow file extension substitution. +<p> +<ul> +<li>eg remapExtension("dds", "tga", true) Where the boolean indicates whether the "dds" should replace a "tga" if one exists - again - a warning should be generated if the two are present.</ul> +ie: If you have a file called pic.dds and you call remapExtension("dds", "tga", true), if you call lookup("pic.tga"), it'll return "pic.dds" +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00127">127</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="cf__lexical_8cpp-source.html#l02654">file</a>, <a class="el" href="path_8cpp-source.html#l00881">insertFileInMap</a>, <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>, <a class="el" href="debug_8h-source.html#l00254">nlassert</a>, <a class="el" href="debug_8h-source.html#l00114">nlwarning</a>, and <a class="el" href="common_8cpp-source.html#l00426">NLMISC::strlwr</a>. </td> + </tr> +</table> +<a name="d5" doxytag="NLMISC::CPath::removeAllAlternativeSearchPath"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CPath::removeAllAlternativeSearchPath </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Remove all search path contains in the alternative directories. +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00615">615</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +References <a class="el" href="path_8cpp-source.html#l00069">NL_DISPLAY_PATH</a>. </td> + </tr> +</table> +<a name="d12" doxytag="NLMISC::CPath::standardizeDosPath"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> std::string NLMISC::CPath::standardizeDosPath </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname1" valign="top" nowrap> <em>path</em> </td> + <td class="md" valign="top">) </td> + <td class="md" nowrap><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Remplace / with \ for fucking dos process. +<p> +Use only this function if can't do another way. For exemple, if you do a system("copy data/toto data/tata"); it'll not work because dos doesn't understand /. But in the majority of case, / working (it works for fopen for example) +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00327">327</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. </td> + </tr> +</table> +<a name="d11" doxytag="NLMISC::CPath::standardizePath"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> string NLMISC::CPath::standardizePath </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::string & </td> + <td class="mdname" nowrap> <em>path</em>, </td> + </tr> + <tr> + <td></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>addFinalSlash</em> = true</td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [static]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Take a path and put it in the portable format and add a terminated / if needed ie: "C:\Game/dir1" will become "C:/Game/dir1/" or "C:/Game/dir1" if addFinalSlash is false. +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00296">296</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00708">addSearchFile</a>, <a class="el" href="path_8cpp-source.html#l00623">addSearchPath</a>, <a class="el" href="path_8cpp-source.html#l00360">getFullPath</a>, and <a class="el" href="path_8cpp-source.html#l00523">getPathContent</a>. </td> + </tr> +</table> +<hr><h2>Member Data Documentation</h2> +<a name="o0" doxytag="NLMISC::CPath::_AlternativePaths"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> std::vector<std::string> NLMISC::CPath::_AlternativePaths<code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="path_8h-source.html#l00185">185</a> of file <a class="el" href="path_8h-source.html">path.h</a>. </td> + </tr> +</table> +<a name="o2" doxytag="NLMISC::CPath::_Extensions"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> std::vector<std::pair<std::string, std::string> > NLMISC::CPath::_Extensions<code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +first ext1, second ext2 (ext1 could remplace ext2). +<p> + +<p> +Definition at line <a class="el" href="path_8h-source.html#l00201">201</a> of file <a class="el" href="path_8h-source.html">path.h</a>. </td> + </tr> +</table> +<a name="o1" doxytag="NLMISC::CPath::_Files"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> std::map<std::string, <a class="el" href="structNLMISC_1_1CPath_1_1CFileEntry.html">CFileEntry</a>> NLMISC::CPath::_Files<code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +first is the filename, second the full path for the filename. +<p> +Due to the remapping, first and second.path could have different extention. +<p> +Definition at line <a class="el" href="path_8h-source.html#l00198">198</a> of file <a class="el" href="path_8h-source.html">path.h</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00085">getFileList</a>. </td> + </tr> +</table> +<a name="r0" doxytag="NLMISC::CPath::_Instance"></a><p> +<table width="100%" cellpadding="2" cellspacing="0" border="0"> + <tr> + <td class="md"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> CPath * NLMISC::CPath::_Instance = NULL<code> [static, private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="path_8cpp-source.html#l00078">78</a> of file <a class="el" href="path_8cpp-source.html">path.cpp</a>. +<p> +Referenced by <a class="el" href="path_8cpp-source.html#l00098">getInstance</a>. </td> + </tr> +</table> +<hr>The documentation for this class was generated from the following files:<ul> +<li><a class="el" href="path_8h-source.html">path.h</a><li><a class="el" href="path_8cpp-source.html">path.cpp</a></ul> + + +<!-- footer --> +<BR><FONT Size=+5> </FONT> +</TD> +<TD WIDTH=15><IMG SRC=http://www.nevrax.org/inc/img/pixel.gif WIDTH=15 HEIGHT=15 BORDER=0 ALT=""></TD> +</TR> +</TABLE> +</BODY> +</HTML> |