
#include <Gestalt.h>
Boolean CanDoAsyncSCSI(void)
{
long response;
OSErr err;
err = Gestalt(gestaltSCSI, &response);
if (err) return false;
return (response & (1 << gestaltAsyncSCSI) );
}
There is no Gestalt test currently available for non-SCSI devices. You can
assume that asynchronous calls to a driver will be handled correctly. If the
driver is actually asynchronous, your completion routine is called when the I/O
is finished. If the driver is not asynchronous, the driver returns and calls
your completion routine when the I/O is finished.
For more information, see the SCSI Manager 4.3 chapter of Inside
Macintosh:Devices and "Asynchronous routines on the Macintosh" in
issue 13 of Develop.
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help