File Handling

Table of Contents

Basic File Operations -
Reading and Writing -
Getting and Setting File Information -
Truncating Files -
Advanced File Operations -
Asynchronous File Operations - POSIX-style file operations that run outside your main loop

GnomeVFS file operations are, for the most part, patterned after their POSIX equivalents, with the systematic difference that they accept URIs rather than paths on the local filesystem. This makes them easy to learn as if you are already familiar with basic commands such as open(), seek(), write(), etc you will feel right at home with GnomeVFS after learning a little about URIs.

GnomeVFS also provides asynchronous versions of these basic operations for allowing application developers to provide non-blocking file I/O without the use of threads.