uml_generator/project/examples/directory.umlg

50 lines
1.1 KiB
Plaintext
Raw Normal View History

2022-04-27 14:57:41 +02:00
2022-04-27 15:21:16 +02:00
class Object
inherit
class Reference
inherit
2022-04-27 14:57:41 +02:00
class Directory
public:
Error open_dir(const String &path, bool skip_specials = true);
Error open_dir(const char *path, bool skip_specials = true);
void close_dir();
2022-04-27 15:21:16 +02:00
--
2022-04-27 14:57:41 +02:00
bool has_next();
bool read();
bool next();
2022-04-27 15:21:16 +02:00
--
2022-04-27 14:57:41 +02:00
bool current_is_ok();
String current_get_name();
String current_get_path();
String current_get_extension();
const char *current_get_name_cstr();
const char *current_get_path_cstr();
const char *current_get_extension_cstr();
bool current_is_file();
bool current_is_dir();
bool current_is_special_dir();
2022-04-27 15:21:16 +02:00
--
2022-04-27 14:57:41 +02:00
String read_file(const String &path);
Error read_file_into(const String &path, String *str);
Vector<uint8_t> read_file_bin(const String &path);
Error read_file_into_bin(const String &path, Vector<uint8_t> *data);
2022-04-27 15:21:16 +02:00
--
2022-04-27 14:57:41 +02:00
Error write_file(const String &path, const String &str);
Error write_file_bin(const String &path, const Vector<uint8_t> &data);
2022-04-27 15:21:16 +02:00
--
2022-04-27 14:57:41 +02:00
bool is_dir_open();
bool is_dir_closed();
2022-04-27 15:21:16 +02:00
--
2022-04-27 14:57:41 +02:00
Directory();
virtual ~Directory();
2022-04-27 15:21:16 +02:00
--
2022-04-27 14:57:41 +02:00
private:
bool _skip_specials;
int _read_file_result;
tinydir_dir _dir;
tinydir_file _file;
bool _dir_open;