API File: Difference between revisions
Appearance
XML import |
XML import |
||
| (8 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
<sidebar>API | <sidebar>API Contents</sidebar> | ||
File reading and writing operations | File reading and writing operations | ||
__TOC__ | __TOC__ | ||
| Line 60: | Line 61: | ||
==Constants provided for this class== | ==Constants provided for this class== | ||
{| class="wikitable" | {| class="wikitable" width="85%" | ||
|+ Used by [[API File.SetPos|SetPos]]() | |||
|- | |- | ||
!width=" | !width="10%"|Type | ||
!width=" | !width="20%"|Name | ||
!width=" | !width="20%"|Value | ||
!width="60%"|Description | |||
|- | |- | ||
|LONG | |LONG | ||
|Seek_Begin | |Seek_Begin | ||
|0 | |0 | ||
|Position offset is an absolute value | |||
|- | |- | ||
|LONG | |LONG | ||
|Seek_Curr | |Seek_Curr | ||
|1 | |1 | ||
|Position offset is relative to the current read/write position | |||
|- | |- | ||
|LONG | |LONG | ||
|Seek_End | |Seek_End | ||
|2 | |2 | ||
|Position offset is relative to the end of the file | |||
|} | |} | ||
==Examples== | ==Examples== | ||
''<span style="color:red;">No additional | ''<span style="color:red;">No additional examples</span>'' | ||
==See also== | ==See also== | ||
''<span style="color:red;">No additional information</span>'' | ''<span style="color:red;">No additional information</span>'' | ||
Latest revision as of 15:57, 16 January 2014
<sidebar>API Contents</sidebar> File reading and writing operations
Sub-classes provided for this class
| Buffer | Reads writes and monitors circular buffers |
| NVM | Reads from a file as though a block of NVM |
Functions provided for this class
| AbsPath | Gets an absolute path from a relative filename |
| RelPath | Gets an relative path from an absolute filename |
| CreateDir | Creates a directory structure |
| GetType | Finds the type of a file: 0=Unknown, 1=File, 2=Dir, 4=Disk |
| GetSize | Gets the number of bytes in the file, by handle or name |
| Delete | Deletes the file or directory structure |
| Create | Creates the new file as a standard stream |
| Open | Opens the existing file as a standard stream |
| ReadArray | Reads an array from the file, returns elements read |
| WriteArray | Writes an array to the file |
| SetPos | Sets the position of the next read or write in the file |
| GetPos | Gets the position of the next read or write in the file |
| Flush | Writes all unwritten data to the file in one block |
Constants provided for this class
| Type | Name | Value | Description |
|---|---|---|---|
| LONG | Seek_Begin | 0 | Position offset is an absolute value |
| LONG | Seek_Curr | 1 | Position offset is relative to the current read/write position |
| LONG | Seek_End | 2 | Position offset is relative to the end of the file |
Examples
No additional examples
See also
No additional information