1 #ifndef CLIB_ASYNCIO_PROTOS_H 2 #define CLIB_ASYNCIO_PROTOS_H 3 4 struct ExecBase; 5 struct DosLibrary; 6 7 8 #ifndef LIBRARIES_ASYNCIO_H 9 #include <libraries/asyncio.h> 10 #endif 11 12 #ifdef __cplusplus 13 extern "C" { 14 #endif /* __cplusplus */ 15 16 struct Hook; 17 18 #ifdef ASIO_NOEXTERNALS 19 AsyncFile * OpenAsync( const STRPTR fileName, OpenModes mode, LONG bufferSize, struct ExecBase *SysBase, struct DosLibrary *DOSBase ); 20 AsyncFile * OpenAsyncFromFH( BPTR handle, OpenModes mode, LONG bufferSize, struct ExecBase *SysBase, struct DosLibrary *DOSBase ); 21 #else 22 AsyncFile * OpenAsync( const STRPTR fileName, OpenModes mode, LONG bufferSize ); 23 AsyncFile * OpenAsyncFromFH( BPTR handle, OpenModes mode, LONG bufferSize ); 24 #endif 25 LONG CloseAsync( AsyncFile *file ); 26 LONG PeekAsync( AsyncFile *file, APTR buffer, LONG numBytes ); 27 LONG ReadAsync( AsyncFile *file, APTR buffer, LONG numBytes ); 28 LONG ReadCharAsync( AsyncFile *file ); 29 LONG ReadLineAsync( AsyncFile *file, APTR buffer, LONG size ); 30 APTR FGetsAsync( AsyncFile *file, APTR buffer, LONG size ); 31 APTR FGetsLenAsync( AsyncFile *file, APTR buffer, LONG size, LONG *length ); 32 LONG WriteAsync( AsyncFile *file, APTR buffer, LONG numBytes ); 33 LONG WriteCharAsync( AsyncFile *file, UBYTE ch ); 34 LONG WriteLineAsync( AsyncFile *file, STRPTR line ); 35 LONG SeekAsync( AsyncFile *file, LONG position, SeekModes mode); 36 QUAD SeekAsync64( AsyncFile *file, QUAD position, SeekModes mode); 37 LONG ReadAsyncPkt( AsyncFile *file, struct Hook *hook, LONG numBytes ); 38 39 #ifdef __cplusplus 40 } 41 #endif /* __cplusplus */ 42 43 #endif /* CLIB_LIBRARIES_ASYNCIO_H */