BeRTOS
kfile_fifo.h
Go to the documentation of this file.
00001 
00062 #ifndef STRUCT_KFILE_FIFO
00063 #define STRUCT_KFILE_FIFO
00064 
00065 #include "fifobuf.h"
00066 #include <io/kfile.h>
00067 
00068 typedef struct KFileFifo
00069 {
00070         KFile fd;
00071         FIFOBuffer *fifo;
00072 } KFileFifo;
00073 
00077 #define KFT_KFILEFIFO MAKE_ID('F', 'I', 'F', '0')
00078 
00082 INLINE KFileFifo * KFILEFIFO_CAST(KFile *fd)
00083 {
00084     ASSERT(fd->_type == KFT_KFILEFIFO);
00085     return (KFileFifo *)fd;
00086 }
00087 
00094 void kfilefifo_init(KFileFifo *kf, FIFOBuffer *fifo);
00095 
00096 int kfilefifo_testSetup(void);
00097 int kfilefifo_testRun(void);
00098 int kfilefifo_testTearDown(void);
00099 #endif /* STRUCT_KFILE_FIFO */