21 #ifndef LIBOPENRAW_IO_H_
22 #define LIBOPENRAW_IO_H_
24 #include <sys/types.h>
51 void* (*mmap) (
IOFileRef f,
size_t l, off_t offset);
52 int (*munmap) (
IOFileRef f,
void *addr,
size_t l);
55 extern struct io_methods* get_default_io_methods(
void);
60 extern int raw_seek(
IOFileRef f, off_t offset,
int whence);
61 extern int raw_read(
IOFileRef f,
void *buf,
size_t count);
63 extern void *raw_mmap(
IOFileRef f,
size_t l, off_t offset);
64 extern int raw_munmap(
IOFileRef f,
void *addr,
size_t l);
int(* seek)(IOFileRef f, off_t offset, int whence)
IOFileRef(* open)(const char *path, int mode)
int(* close)(IOFileRef f)
int(* read)(IOFileRef f, void *buf, size_t count)