blob: a086b906467c5e571c5329e5e7fb43b1b38c164b [file]
#pragma once
#include <cstdint>
#include <string>
#include <vector>
#include "engine/file.hpp"
void setup_base_path();
void *open_file(std::string file, int mode);
int32_t read_file(void *fh, uint32_t offset, uint32_t length, char *buffer);
int32_t write_file(void *fh, uint32_t offset, uint32_t length, const char *buffer);
int32_t close_file(void *fh);
uint32_t get_file_length(void *fh);
std::vector<blit::FileInfo> list_files(std::string path);
bool file_exists(std::string path);
bool directory_exists(std::string path);
bool create_directory(std::string path);
bool rename_file(std::string old_name, std::string new_name);
bool remove_file(std::string path);