Exports for User.
Using this library in your project
Include the header file in your project:
Link the library to the executable:
|
SceUID | sceIoOpen (const char *file, int flags, SceMode mode) |
| Open or create a file for reading or writing. More...
|
|
int | sceIoClose (SceUID fd) |
| Delete a descriptor. More...
|
|
SceSSize | sceIoRead (SceUID fd, void *buf, SceSize nbyte) |
| Read input. More...
|
|
int | sceIoPread (SceUID fd, void *data, SceSize size, SceOff offset) |
| Read input at offset. More...
|
|
SceSSize | sceIoWrite (SceUID fd, const void *buf, SceSize nbyte) |
| Write output. More...
|
|
int | sceIoPwrite (SceUID fd, const void *data, SceSize size, SceOff offset) |
| Write output at offset. More...
|
|
SceOff | sceIoLseek (SceUID fd, SceOff offset, int whence) |
| Reposition read/write file descriptor offset. More...
|
|
long | sceIoLseek32 (SceUID fd, long offset, int whence) |
| Reposition read/write file descriptor offset (32bit mode) More...
|
|
int | sceIoRemove (const char *file) |
| Remove directory entry. More...
|
|
int | sceIoRename (const char *oldname, const char *newname) |
| Change the name of a file. More...
|
|
int | sceIoSync (const char *device, unsigned int unk) |
| Synchronize the file data on the device. More...
|
|
int | sceIoSyncByFd (SceUID fd, int flag) |
| Synchronize the file data for one file. More...
|
|
int | sceIoCancel (SceUID fd) |
| Cancel an asynchronous operation on a file descriptor. More...
|
|
int | sceIoGetPriority (SceUID fd) |
|
int | sceIoGetProcessDefaultPriority (void) |
|
int | sceIoGetThreadDefaultPriority (void) |
|
int | sceIoSetPriority (SceUID fd, int priority) |
|
int | sceIoSetProcessDefaultPriority (int priority) |
|
int | sceIoSetThreadDefaultPriority (int priority) |
|
◆ sceIoOpen()
Open or create a file for reading or writing.
- Example1: Open a file for reading
}
SceUID sceIoOpen(const char *file, int flags, SceMode mode)
Open or create a file for reading or writing.
@ SCE_O_RDONLY
Read-only.
Definition: iofilemgr.h:29
- Example2: Open a file for writing, creating it if it doesn't exist
}
@ SCE_O_WRONLY
Write-only.
Definition: iofilemgr.h:30
@ SCE_O_CREAT
Create.
Definition: iofilemgr.h:37
- Parameters
-
file | - Pointer to a string holding the name of the file to open. |
flags | - Libc styled flags that are or'ed together (One or more SceIoMode). |
mode | - One or more SceIoAccessMode flags or'ed together. Can also use Unix absolute permissions. |
- Returns
- > 0 is a valid file handle, < 0 on error.
◆ sceIoClose()
Delete a descriptor.
int sceIoClose(SceUID fd)
Delete a descriptor.
- Parameters
-
fd | - File descriptor to close |
- Returns
- < 0 on error
◆ sceIoRead()
Read input.
- Example:
SceSSize sceIoRead(SceUID fd, void *buf, SceSize nbyte)
Read input.
- Parameters
-
fd | - Opened file descriptor to read from |
buf | - Pointer to the buffer where the read data will be placed |
nbyte | - Size of the read in bytes |
- Returns
- The number of bytes read
◆ sceIoPread()
Read input at offset.
- Example:
int sceIoPread(SceUID fd, void *data, SceSize size, SceOff offset)
Read input at offset.
- Parameters
-
fd | - Opened file descriptor to read from |
data | - Pointer to the buffer where the read data will be placed |
size | - Size of the read in bytes |
offset | - Offset to read |
- Returns
- < 0 on error.
◆ sceIoWrite()
Write output.
- Example:
SceSSize sceIoWrite(SceUID fd, const void *buf, SceSize nbyte)
Write output.
- Parameters
-
fd | - Opened file descriptor to write to |
buf | - Pointer to the data to write |
nbyte | - Size of data to write |
- Returns
- The number of bytes written
◆ sceIoPwrite()
Write output at offset.
- Example:
int sceIoPwrite(SceUID fd, const void *data, SceSize size, SceOff offset)
Write output at offset.
- Parameters
-
fd | - Opened file descriptor to write to |
data | - Pointer to the data to write |
size | - Size of data to write |
offset | - Offset to write |
- Returns
- The number of bytes written
◆ sceIoLseek()
Reposition read/write file descriptor offset.
- Example:
SceOff sceIoLseek(SceUID fd, SceOff offset, int whence)
Reposition read/write file descriptor offset.
@ SCE_SEEK_END
Starts from the end of the file.
Definition: iofilemgr.h:52
- Parameters
-
fd | - Opened file descriptor with which to seek |
offset | - Relative offset from the start position given by whence |
whence | - One of SceIoSeekMode. |
- Returns
- The position in the file after the seek.
◆ sceIoLseek32()
long sceIoLseek32 |
( |
SceUID |
fd, |
|
|
long |
offset, |
|
|
int |
whence |
|
) |
| |
Reposition read/write file descriptor offset (32bit mode)
- Example:
long sceIoLseek32(SceUID fd, long offset, int whence)
Reposition read/write file descriptor offset (32bit mode)
- Parameters
-
fd | - Opened file descriptor with which to seek |
offset | - Relative offset from the start position given by whence |
whence | - One of SceIoSeekMode. |
- Returns
- The position in the file after the seek.
◆ sceIoRemove()
int sceIoRemove |
( |
const char * |
file | ) |
|
Remove directory entry.
- Parameters
-
file | - Path to the file to remove |
- Returns
- < 0 on error
◆ sceIoRename()
int sceIoRename |
( |
const char * |
oldname, |
|
|
const char * |
newname |
|
) |
| |
Change the name of a file.
- Parameters
-
oldname | - The old filename |
newname | - The new filename |
- Returns
- < 0 on error.
◆ sceIoSync()
int sceIoSync |
( |
const char * |
device, |
|
|
unsigned int |
unk |
|
) |
| |
Synchronize the file data on the device.
- Parameters
-
device | - The device to synchronize (e.g. msfat0:) |
unk | - Unknown |
◆ sceIoSyncByFd()
int sceIoSyncByFd |
( |
SceUID |
fd, |
|
|
int |
flag |
|
) |
| |
Synchronize the file data for one file.
- Parameters
-
fd | - Opened file descriptor to sync |
flag | - unknown |
- Returns
- < 0 on error.
◆ sceIoCancel()
Cancel an asynchronous operation on a file descriptor.
- Parameters
-
fd | - The file descriptor to perform cancel on. |
- Returns
- < 0 on error.
◆ sceIoGetPriority()
int sceIoGetPriority |
( |
SceUID |
fd | ) |
|
◆ sceIoGetProcessDefaultPriority()
int sceIoGetProcessDefaultPriority |
( |
void |
| ) |
|
◆ sceIoGetThreadDefaultPriority()
int sceIoGetThreadDefaultPriority |
( |
void |
| ) |
|
◆ sceIoSetPriority()
int sceIoSetPriority |
( |
SceUID |
fd, |
|
|
int |
priority |
|
) |
| |
◆ sceIoSetProcessDefaultPriority()
int sceIoSetProcessDefaultPriority |
( |
int |
priority | ) |
|
◆ sceIoSetThreadDefaultPriority()
int sceIoSetThreadDefaultPriority |
( |
int |
priority | ) |
|