2.8. Asynchronous File Operations

The APIs supports an asynchronous form of file access that allows you to start an I/O operation and then proceed with other activities while the operation completes in the background. The technique is referred to asoverlapped I/O. It exists in Windows for two reasons:

  1. Overlapped I/O lets you create the impression of multi-threading without actually implementing a separate thread. In certain situations this makes the code more compact, or lets you handle asynchronous file I/O more easily than a second thread would.

  2. Overlapped I/O makes it possible for separate threads in a single program to manipulate the same file object simultaneously. With overlapped I/O, each thread can keep track of its file position independently ...

Get Win32 System Services: The Heart of Windows® 98 and Windows® 2000 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.