⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 filemanager.html

📁 qtopiaphone英文帮助,用于初学者和开发人员,初学者可以用来学习,开发人员可以用来资料查询.
💻 HTML
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><!-- /home/edba/dist/qtopia/main-Sunday/qtopia/src/libraries/qtopia/filemanager.cpp:37 --><html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>FileManager Class</title><style type="text/css"><!--h3.fn,span.fn { margin-left: 1cm; text-indent: -1cm; }a:link { color: #004faf; text-decoration: none }a:visited { color: #672967; text-decoration: none }body { background: #ffffff; color: black; }--></style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td width="200" align="left" valign="top"><a href="index.html"><img height="27" width="472" src="dochead.png" border="0"></a><br><font face="Arial,Helvetica,Geneva,Swiss,SunSans-Regular" align="center" size=32>Qtopia</font>   <a href="index.html">Home</a> - <a href="qtopiaclasses.html">Classes</a> - <a href="qtopiaannotated.html">Annotated</a> - <a href="qtopiafunctions.html">Functions</a> - <a href="qtindex.html">Qt Embedded</a></td><td align="right" valign="top">  <table border="0" cellpadding="0" cellspacing="0" width="137">  <tr>  <td><a href="http://www.trolltech.com/company/about/trolls.html"><img height="100" width="100" src="face.png" border="0"></a></td>  <td><img height="100" width="100" src="qtlogo.png" align="top" border="0"></td>  </tr>  </table></td></tr></table><h1 align=center>FileManager Class Reference</h1><p>The FileManager class assists with AppLnk input/output.<a href="#details">More...</a><p><tt>#include &lt;<a href="filemanager-h.html">filemanager.h</a>&gt;</tt><p><a href="filemanager-members.html">List of all member functions.</a><h2>Public Members</h2><ul><li><div class=fn><a href="#FileManager"><b>FileManager</b></a> ()</div></li><li><div class=fn><a href="#~FileManager"><b>~FileManager</b></a> ()</div></li><li><div class=fn>bool <a href="#saveFile-2"><b>saveFile</b></a> ( const&nbsp;DocLnk&nbsp;&amp;&nbsp;f, const&nbsp;QByteArray&nbsp;&amp;&nbsp;data )</div></li><li><div class=fn>bool <a href="#saveFile"><b>saveFile</b></a> ( const&nbsp;DocLnk&nbsp;&amp;&nbsp;f, const&nbsp;QString&nbsp;&amp;&nbsp;text )</div></li><li><div class=fn>bool <a href="#loadFile"><b>loadFile</b></a> ( const&nbsp;DocLnk&nbsp;&amp;&nbsp;f, QByteArray&nbsp;&amp;&nbsp;ba )</div></li><li><div class=fn>bool <a href="#loadFile-2"><b>loadFile</b></a> ( const&nbsp;DocLnk&nbsp;&amp;&nbsp;f, QString&nbsp;&amp;&nbsp;text )</div></li><li><div class=fn>bool <a href="#copyFile"><b>copyFile</b></a> ( const&nbsp;AppLnk&nbsp;&amp;&nbsp;src, const&nbsp;AppLnk&nbsp;&amp;&nbsp;dest )</div></li><li><div class=fn>QIODevice * <a href="#openFile"><b>openFile</b></a> ( const&nbsp;DocLnk&nbsp;&amp;&nbsp;f )</div></li><li><div class=fn>QIODevice * <a href="#saveFile-3"><b>saveFile</b></a> ( const&nbsp;DocLnk&nbsp;&amp;&nbsp;f )</div></li><li><div class=fn>bool <a href="#exists"><b>exists</b></a> ( const&nbsp;DocLnk&nbsp;&amp;&nbsp;f )</div></li></ul><h2>Protected Members</h2><ul><li><div class=fn>bool <a href="#ensurePathExists"><b>ensurePathExists</b></a> ( const&nbsp;QString&nbsp;&amp;&nbsp;fn )</div></li></ul><hr><a name="details"></a><h2>Detailed Description</h2>The FileManager class assists with <a href="applnk.html">AppLnk</a> input/output.<p> The FileManager class is used to <a href="#loadFile">loadFile</a>()s and<a href="#saveFile">saveFile</a>()s. It also provides a <a href="#copyFile">copyFile</a>() function and afunction to test for a file's existence, <a href="#exists">exists</a>(). It also provides<a href="#openFile">openFile</a>() that provides an IO device for reading.<p> <p>See also <a href="qtopiaemb.html">Qtopia Classes</a>.<hr><h2>Member Function Documentation</h2><h3 class=fn><a name="FileManager"></a>FileManager::FileManager ()</h3>Constructs a FileManager object.<h3 class=fn><a name="~FileManager"></a>FileManager::~FileManager ()</h3>Destroys the FileManager object.<h3 class=fn>bool <a name="copyFile"></a>FileManager::copyFile ( const&nbsp;<a href="applnk.html">AppLnk</a>&nbsp;&amp;&nbsp;src, const&nbsp;<a href="applnk.html">AppLnk</a>&nbsp;&amp;&nbsp;dest )</h3>Copies the document specified by <em>src</em> to the document specifiedby <em>dest</em>.<p> Returns TRUE if the operation succeeded; otherwise returns FALSE.<h3 class=fn>bool <a name="ensurePathExists"></a>FileManager::ensurePathExists ( const&nbsp;QString&nbsp;&amp;&nbsp;fn )<tt> [protected]</tt></h3>Ensures that the path <em>fn</em> exists, by creating required directories.<p> Returns TRUE if it succeededs; otherwise returns FALSE.<h3 class=fn>bool <a name="exists"></a>FileManager::exists ( const&nbsp;<a href="doclnk.html">DocLnk</a>&nbsp;&amp;&nbsp;f )</h3>Returns TRUE if the document specified by <em>f</em> current existsas a file on disk; otherwise returns FALSE.<h3 class=fn>bool <a name="loadFile"></a>FileManager::loadFile ( const&nbsp;<a href="doclnk.html">DocLnk</a>&nbsp;&amp;&nbsp;f, QByteArray&nbsp;&amp;&nbsp;ba )</h3>Loads <em>ba</em> from the document specified by <em>f</em>.<p> Returns TRUE if the operation succeeded; otherwise returns FALSE.<h3 class=fn>bool <a name="loadFile-2"></a>FileManager::loadFile ( const&nbsp;<a href="doclnk.html">DocLnk</a>&nbsp;&amp;&nbsp;f, QString&nbsp;&amp;&nbsp;text )</h3>This is an overloaded member function, provided for convenience. It behaves essentially like the above function.<p> Loads <em>text</em> from the document specified by <em>f</em>.<p> The text must be in UTF8 format.<p> Returns TRUE if the operation succeeded; otherwise returns FALSE.<h3 class=fn>QIODevice * <a name="openFile"></a>FileManager::openFile ( const&nbsp;<a href="doclnk.html">DocLnk</a>&nbsp;&amp;&nbsp;f )</h3>Opens the document specified by <em>f</em> as a readable QIODevice.The caller must delete the return value.<p> Returns 0 if the operation fails.<h3 class=fn>bool <a name="saveFile"></a>FileManager::saveFile ( const&nbsp;<a href="doclnk.html">DocLnk</a>&nbsp;&amp;&nbsp;f, const&nbsp;QString&nbsp;&amp;&nbsp;text )</h3>Saves <em>text</em> as the document specified by <em>f</em>.<p> The text is saved in UTF8 format.<p> Returns TRUE if the operation succeeded; otherwise returns FALSE.<h3 class=fn>bool <a name="saveFile-2"></a>FileManager::saveFile ( const&nbsp;<a href="doclnk.html">DocLnk</a>&nbsp;&amp;&nbsp;f, const&nbsp;QByteArray&nbsp;&amp;&nbsp;data )</h3>This is an overloaded member function, provided for convenience. It behaves essentially like the above function.<p> Saves <em>data</em> as the document specified by <em>f</em>.<p> Returns TRUE if the operation succeeded; otherwise returns FALSE.<h3 class=fn>QIODevice * <a name="saveFile-3"></a>FileManager::saveFile ( const&nbsp;<a href="doclnk.html">DocLnk</a>&nbsp;&amp;&nbsp;f )</h3>This is an overloaded member function, provided for convenience. It behaves essentially like the above function.<p> Opens the document specified by <em>f</em> as a writable QIODevice.The caller must delete the return value.<p> Returns 0 if the operation fails.<!-- eof --><hr><p>This file is part of the <a href="../index.html">Qtopia</a> platform,copyright &copy; 1995-2004<a href="http://www.trolltech.com/">Trolltech</a>, all rights reserved.<p><address><hr><div align="center"><table width="100%" cellspacing="0" border="0"><tr><td>Copyright &copy; 2001-2004 Trolltech<td><a href="http://www.trolltech.com/trademarks.html">Trademarks</a><td align="right"><div align="right">Qtopia version 2.0.0</div></table></div></address></body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -