aboutsummaryrefslogtreecommitdiff
path: root/include/bh/internal/file.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/bh/internal/file.h')
-rw-r--r--include/bh/internal/file.h34
1 files changed, 33 insertions, 1 deletions
diff --git a/include/bh/internal/file.h b/include/bh/internal/file.h
index 1e9fed0..20c6c31 100644
--- a/include/bh/internal/file.h
+++ b/include/bh/internal/file.h
@@ -16,6 +16,38 @@
int bh_file_init(bh_file_t *file,
const char *path);
-void bh_file_destroy(bh_file_t *file);
+#define bh_file_destroy(file) \
+ bh_io_destroy((bh_io_t *)(file))
+
+void bh_file_destroy_base(bh_file_t *file);
+
+int bh_file_open_base(bh_file_t *file,
+ int mode);
+
+void bh_file_close_base(bh_file_t *file);
+
+int bh_file_is_open_base(bh_file_t *file);
+
+size_t bh_file_read_base(bh_file_t *file,
+ char *data,
+ size_t size);
+
+size_t bh_file_write_base(bh_file_t *file,
+ const char *data,
+ size_t size);
+
+void bh_file_flush_base(bh_file_t *file);
+
+int bh_file_seek_base(bh_file_t *file,
+ bh_off_t pos,
+ int dir);
+
+bh_off_t bh_file_size_base(bh_file_t *file);
+
+bh_off_t bh_file_tell_base(bh_file_t *file);
+
+bh_off_t bh_file_available_base(bh_file_t *file);
+
+void bh_file_clear_base(bh_file_t *file);
#endif /* BH_INTERNAL_FILE_H */