59typedef void *(* MIOReallocFunc) (
void *
ptr,
size_t size);
71typedef FILE *(* MIOFOpenFunc) (
const char *
filename,
const char *mode);
#define CTAGS_ATTR_PRINTF(s, f)
unsigned char * mio_memory_get_data(MIO *mio, size_t *size)
mio_memory_get_data: @mio: A MIO object @size: (allow-none) (out): Return location for the length of ...
MIO * mio_new_fp(FILE *fp, MIOFCloseFunc close_func)
mio_new_fp: @fp: An opened #FILE object @close_func: (allow-none): Function used to close @fp when th...
size_t mio_write(MIO *mio, const void *ptr, size_t size, size_t nmemb)
mio_write: @mio: A MIO object @ptr: Pointer to the memory to write on the stream @size: Size of each ...
int mio_getc(MIO *mio)
mio_getc: @mio: A MIO object
long mio_tell(MIO *mio)
mio_tell: @mio: A MIO object
MIO * mio_new_file(const char *filename, const char *mode)
mio_new_file: @filename: Filename to open, same as the fopen()'s first argument @mode: Mode in which ...
int mio_vprintf(MIO *mio, const char *format, va_list ap)
mio_vprintf: @mio: A MIO object @format: A printf format string @ap: The variadic argument list for t...
void mio_clearerr(MIO *mio)
mio_clearerr: @mio: A MIO object
int mio_seek(MIO *mio, long offset, int whence)
mio_seek: @mio: A MIO object @offset: Offset of the new place, from @whence @whence: Move origin.
int mio_eof(MIO *mio)
mio_eof: @mio: A MIO object
_MIOType
MIOType: @MIO_TYPE_FILE: MIO object works on a file @MIO_TYPE_MEMORY: MIO object works in-memory.
void * mio_get_user_data(MIO *mio)
mio_get_user_data: @mio: A MIO object
int mio_try_resize(MIO *mio, size_t new_size)
int mio_getpos(MIO *mio, MIOPos *pos)
mio_getpos: @mio: A MIO stream @pos: (out): A MIOPos object to fill-in
int mio_flush(MIO *mio)
mio_flush: @mio: A MIO object
void(* MIODestroyNotify)(void *data)
MIODestroyNotify: @data: Data element being destroyed.
MIO * mio_new_file_full(const char *filename, const char *mode, MIOFOpenFunc open_func, MIOFCloseFunc close_func)
mio_new_file_full: @filename: Filename to open, passed as-is to @open_func as the first argument @mod...
int mio_error(MIO *mio)
mio_error: @mio: A MIO object
void mio_rewind(MIO *mio)
mio_rewind: @mio: A MIO object
FILE * mio_file_get_fp(MIO *mio)
mio_file_get_fp: @mio: A MIO object
char * mio_gets(MIO *mio, char *s, size_t size)
mio_gets: @mio: A MIO object @s: A string to fill with the read data @size: The maximum number of byt...
MIO * mio_new_memory(unsigned char *data, size_t size, MIOReallocFunc realloc_func, MIODestroyNotify free_func)
mio_new_memory: @data: Initial data (may be NULL) @size: Length of @data in bytes @realloc_func: A fu...
MIO * mio_new_mio(MIO *base, long start, long size)
mio_new_mio: @base: The original mio @start: stream offset of the @base where new mio starts @size: t...
int mio_printf(MIO *mio, const char *format,...)
mio_printf: @mio: A MIO object @format: A print format string ...: Arguments of the format
int mio_puts(MIO *mio, const char *s)
mio_puts: @mio: A MIO object @s: The string to write
void *(* MIOReallocFunc)(void *ptr, size_t size)
MIOReallocFunc: @ptr: Pointer to the memory to resize @size: New size of the memory pointed by @ptr.
MIO * mio_ref(MIO *mio)
mio_ref: @mio: A MIO object
int mio_ungetc(MIO *mio, int ch)
mio_ungetc: @mio: A MIO object @ch: Character to put back in the stream
FILE *(* MIOFOpenFunc)(const char *filename, const char *mode)
MIOFOpenFunc: @filename: The filename to open @mode: fopen() modes for opening @filename.
size_t mio_read(MIO *mio, void *ptr, size_t size, size_t nmemb)
mio_read: @mio: A MIO object @ptr: Pointer to the memory to fill with the read data @size: Size of ea...
int mio_putc(MIO *mio, int c)
mio_putc: @mio: A MIO object : The character to write
int(* MIOFCloseFunc)(FILE *fp)
MIOFCloseFunc: @fp: An opened #FILE object.
int mio_unref(MIO *mio)
mio_unref: @mio: A MIO object
void mio_attach_user_data(MIO *mio, void *user_data, MIODestroyNotify user_data_free_func)
mio_attach_user_data: @mio: A MIO object @user_data: a pointer to any data object @user_data_free_fun...
int mio_setpos(MIO *mio, MIOPos *pos)
mio_setpos: @mio: A MIO object @pos: (in): A MIOPos object filled-in by a previous call of mio_getpos...