fatfs v0.08b Jan 15,2011:
- Fast seek feature is also applied to f_read() and f_write(). - f_lseek() reports required table size on creating CLMP. - Extended format syntax of f_printf function. - Ignores duplicated directory separators in given path names.
This commit is contained in:
1 parent
625f3adcbb
commit
5fa1073a5a
98 files changed
+2819
-2235
No files matched your search
+28
-40
@@ -11,18 +11,18 @@
|
||||
|
||||
<body>
|
||||
|
||||
<div class="para">
|
||||
<div class="para func">
|
||||
<h2>f_rename</h2>
|
||||
<p>Renames an object.</p>
|
||||
<pre>
|
||||
FRESULT f_rename (
|
||||
const TCHAR* <em>OldName</em>, <span>/* Pointer to old object name */</span>
|
||||
const TCHAR* <em>NewName</em> <span>/* Pointer to new object name */</span>
|
||||
const TCHAR* <em>OldName</em>, <span class="c">/* Pointer to old object name */</span>
|
||||
const TCHAR* <em>NewName</em> <span class="c">/* Pointer to new object name */</span>
|
||||
);
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<div class="para">
|
||||
<div class="para arg">
|
||||
<h4>Parameters</h4>
|
||||
<dl class="par">
|
||||
<dt>OldName</dt>
|
||||
@@ -33,60 +33,48 @@ FRESULT f_rename (
|
||||
</div>
|
||||
|
||||
|
||||
<div class="para">
|
||||
<div class="para ret">
|
||||
<h4>Return Values</h4>
|
||||
<dl class="ret">
|
||||
<dt>FR_OK (0)</dt>
|
||||
<dd>The function succeeded.</dd>
|
||||
<dt>FR_NO_FILE</dt>
|
||||
<dd>Could not find the old name.</dd>
|
||||
<dt>FR_NO_PATH</dt>
|
||||
<dd>Could not find the path.</dd>
|
||||
<dt>FR_INVALID_NAME</dt>
|
||||
<dd>The file name is invalid.</dd>
|
||||
<dt>FR_INVALID_DRIVE</dt>
|
||||
<dd>The drive number is invalid.</dd>
|
||||
<dt>FR_NOT_READY</dt>
|
||||
<dd>The disk drive cannot work due to no medium in the drive or any other reason.</dd>
|
||||
<dt>FR_EXIST</dt>
|
||||
<dd>The new name is colliding with an existing name.</dd>
|
||||
<dt>FR_DENIED</dt>
|
||||
<dd>The new name could not be created due to any reason.</dd>
|
||||
<dt>FR_WRITE_PROTECTED</dt>
|
||||
<dd>The medium is write protected.</dd>
|
||||
<dt>FR_DISK_ERR</dt>
|
||||
<dd>The function failed due to an error in the disk function.</dd>
|
||||
<dt>FR_INT_ERR</dt>
|
||||
<dd>The function failed due to a wrong FAT structure or an internal error.</dd>
|
||||
<dt>FR_NOT_ENABLED</dt>
|
||||
<dd>The logical drive has no work area.</dd>
|
||||
<dt>FR_NO_FILESYSTEM</dt>
|
||||
<dd>There is no valid FAT volume on the drive.</dd>
|
||||
<dt>FR_LOCKED</dt>
|
||||
<dd>The function was rejected due to file shareing policy (_FS_SHARE).</dd>
|
||||
</dl>
|
||||
<p>
|
||||
<a href="rc.html#ok">FR_OK</a>,
|
||||
<a href="rc.html#de">FR_DISK_ERR</a>,
|
||||
<a href="rc.html#ie">FR_INT_ERR</a>,
|
||||
<a href="rc.html#nr">FR_NOT_READY</a>,
|
||||
<a href="rc.html#ok">FR_NO_FILE</a>,
|
||||
<a href="rc.html#np">FR_NO_PATH</a>,
|
||||
<a href="rc.html#in">FR_INVALID_NAME</a>,
|
||||
<a href="rc.html#de">FR_DENIED</a>,
|
||||
<a href="rc.html#ex">FR_EXIST</a>,
|
||||
<a href="rc.html#wp">FR_WRITE_PROTECTED</a>,
|
||||
<a href="rc.html#id">FR_INVALID_DRIVE</a>,
|
||||
<a href="rc.html#ne">FR_NOT_ENABLED</a>,
|
||||
<a href="rc.html#ns">FR_NO_FILESYSTEM</a>,
|
||||
<a href="rc.html#tm">FR_TIMEOUT</a>,
|
||||
<a href="rc.html#lo">FR_LOCKED</a>,
|
||||
<a href="rc.html#nc">FR_NOT_ENOUGH_CORE</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="para">
|
||||
<div class="para desc">
|
||||
<h4>Description</h4>
|
||||
<p>Renames an object (file or directory) and can also move it to other directory. The logical drive number is determined by old name, new name must not contain a logical drive number. <em>Do not rename open objects</em>.</p>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="para">
|
||||
<div class="para comp">
|
||||
<h4>QuickInfo</h4>
|
||||
<p>Available when <tt>_FS_READONLY == 0</tt> and <tt>_FS_MINIMIZE == 0</tt>.</p>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="para">
|
||||
<div class="para use">
|
||||
<h4>Example</h4>
|
||||
<pre>
|
||||
<span>/* Rename an object */</span>
|
||||
<span class="c">/* Rename an object */</span>
|
||||
f_rename("oldname.txt", "newname.txt");
|
||||
|
||||
<span>/* Rename and move an object to other directory */</span>
|
||||
<span class="c">/* Rename and move an object to other directory */</span>
|
||||
f_rename("oldname.txt", "dir1/newname.txt");
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
Reference in new issue
Block a user