Главная » Статьи » IT |
Библиотека ksfilefunc
Успешно применяю эту свою библиотеку для задач связанных с файловой системой. Расположена на хостинге googlecode. Содержит: Функции как для извлечения/установки части строк в виде пути. Функции обёртки над WinAPI. Функции поиска директорий и файлов. Функции отдельные для ansi и для unicode. size_t ksff::file_size (FILE *const f) bool ksff::is_file_exests (const string &filename) bool ksff::is_file_exests (const wstring &filename) bool ksff::is_directory_exests (const string &directory_) bool ksff::is_directory_exests (const wstring &directory_) string ksff::get_extention (const string &filename) wstring ksff::get_extention (const wstring &filename) string ksff::set_extention (const string &filename, const string &new_extention) wstring ksff::set_extention (const wstring &filename, const wstring &new_extention) string ksff::get_directory (const string &fullpath) wstring ksff::get_directory (const wstring &fullpath) string ksff::get_filename (const string &fullpath) wstring ksff::get_filename (const wstring &fullpath) void ksff::split (string &directory_, string &file_, string &extention_, const string &fullpath) void ksff::split (wstring &directory_, wstring &file_, wstring &extention_, const wstring &fullpath) bool ksff::set_directory_up (string &directory_) bool ksff::set_directory_up (wstring &directory_) void ksff::create_directory (string &directory_) throw (std::runtime_error) void ksff::create_directory (wstring &directory_) throw (std::runtime_error) string ksff::get_fullpath (const string &filename) wstring ksff::get_fullpath (const wstring &filename) string ksff::get_shortpath (const string &src) wstring ksff::get_shortpath (const wstring &src) void ksff::save_to_file (const void *data, const size_t len, const string &filename) throw (std::runtime_error) void ksff::save_to_file (const void *data, const size_t len, const wstring &filename) throw (std::runtime_error) void ksff::save_to_file (const string &txt, const string &filename) throw (std::runtime_error) void ksff::save_to_file (const string &txt, const wstring &filename) throw (std::runtime_error) void ksff::load_from_file_binary (std::vector< BYTE > &dest, const string &filename) throw (std::runtime_error) void ksff::load_from_file_binary (std::vector< BYTE > &dest, const wstring &filename) throw (std::runtime_error) void ksff::load_from_file (string &dest, const string &filename) throw (std::runtime_error) void ksff::load_from_file (string &dest, const wstring &filename) throw (std::runtime_error) string ksff::get_exe_fullpath_ansi () wstring ksff::get_exe_fullpath_wide () string ksff::get_exe_directory_ansi () wstring ksff::get_exe_directory_wide () string ksff::get_module_directory_ansi (HMODULE hm) wstring ksff::get_module_directory_wide (HMODULE hm) bool ksff::search_directory_up (string &dest, const string &sub_directory_, const string &start_directory_fullname) bool ksff::search_directory_up (wstring &dest, const wstring &sub_directory_, const wstring &start_directory_fullname) void ksff::search_files (std::vector< string > &dest, const string &directory_, string &extentions, boolincludeSubFolders) void ksff::search_files (std::vector< wstring > &dest, const wstring &directory_, wstring &extentions, boolincludeSubFolders) | |
Просмотров: 313 | | |
Всего комментариев: 0 | |