#include "octave-config.h"
#include <fstream>
#include <string>
#include <sys/types.h>
#include "lo-ieee.h"
Go to the source code of this file.
Functions | |
int | chdir (const std::string &) |
bool | dir_exists (const std::string &dirname) |
bool | dir_exists (const std::string &dirname, std::string &msg) |
bool | file_exists (const std::string &filename, bool is_dir, std::string &msg) |
bool | file_exists (const std::string &filename, bool is_dir=true) |
std::FILE * | fopen (const std::string &name, const std::string &mode) |
std::FILE * | fopen_tmp (const std::string &name, const std::string &mode) |
std::fstream | fstream (const std::string &name, const std::ios::openmode mode=std::ios::in|std::ios::out) |
std::string | get_ASCII_filename (const std::string &long_file_name, const bool allow_locale=false) |
bool | get_dirlist (const std::string &dirname, string_vector &dirlist, std::string &msg) |
std::string | getcwd () |
std::string | getenv_wrapper (const std::string &) |
std::ifstream | ifstream (const std::string &name, const std::ios::openmode mode=std::ios::in) |
bool | isenv_wrapper (const std::string &) |
std::ofstream | ofstream (const std::string &name, const std::ios::openmode mode=std::ios::out) |
void | putenv_wrapper (const std::string &name, const std::string &value) |
bool | same_file (const std::string &f, const std::string &g) |
int | system (const std::string &cmd_str) |
std::string | u8_from_wstring (const std::wstring &) |
std::wstring | u8_to_wstring (const std::string &) |
int | unsetenv_wrapper (const std::string &) |
int chdir | ( | const std::string & | path_arg | ) |
Definition at line 107 of file lo-sysdep.cc.
References octave_chdir_wrapper(), and octave::sys::file_ops::tilde_expand().
Referenced by interpreter::chdir(), and octave_chdir_wrapper().
bool dir_exists | ( | const std::string & | dirname | ) |
Definition at line 389 of file lo-sysdep.cc.
References dirname(), base_file_stat::is_dir(), and u8_to_wstring().
Referenced by octave::F__ftp_mput__(), octave::F__mkdir__(), Fdrawnow(), octave::genpath(), kpse_element_dir(), base_url_transfer::mget_directory(), base_url_transfer::mput_directory(), and dir_entry::open().
bool dir_exists | ( | const std::string & | dirname, |
std::string & | msg | ||
) |
Definition at line 409 of file lo-sysdep.cc.
References dirname(), base_file_stat::error(), base_file_stat::is_dir(), and u8_to_wstring().
bool file_exists | ( | const std::string & | filename, |
bool | is_dir, | ||
std::string & | msg | ||
) |
Definition at line 362 of file lo-sysdep.cc.
References base_file_stat::error(), base_file_stat::is_dir(), base_file_stat::is_reg(), and u8_to_wstring().
bool file_exists | ( | const std::string & | filename, |
bool | is_dir = true |
||
) |
Definition at line 341 of file lo-sysdep.cc.
References base_file_stat::is_dir(), base_file_stat::is_reg(), and u8_to_wstring().
Referenced by octave::contents_file_in_path(), octave::F__ftp_mput__(), glob(), base_url_transfer::mput_directory(), octave::sys::rename(), and windows_glob().
std::FILE* fopen | ( | const std::string & | name, |
const std::string & | mode | ||
) |
Definition at line 511 of file lo-sysdep.cc.
References u8_to_wstring().
Referenced by fopen_tmp(), and load_path::read_dir_config().
std::FILE* fopen_tmp | ( | const std::string & | name, |
const std::string & | mode | ||
) |
Definition at line 583 of file lo-sysdep.cc.
References fopen(), and octave_unlink_wrapper().
std::fstream fstream | ( | const std::string & | name, |
const std::ios::openmode | mode = std::ios::in|std::ios::out |
||
) |
Definition at line 607 of file lo-sysdep.cc.
References u8_to_wstring().
std::string get_ASCII_filename | ( | const std::string & | long_file_name, |
const bool | allow_locale = false |
||
) |
Definition at line 814 of file lo-sysdep.cc.
References octave::sys::canonicalize_file_name(), dir_sep_chars(), dir_sep_str(), free(), hash(), octave::sys::mkdir(), OCTAVE_LOCAL_BUFFER, octave_locale_charset_wrapper(), octave_u8_conv_to_encoding_strict(), u8_from_wstring(), u8_to_wstring(), and octave::sys::unlink().
Referenced by load_save_system::get_file_format(), and hdf5_fstreambase::open_create().
bool get_dirlist | ( | const std::string & | dirname, |
string_vector & | dirlist, | ||
std::string & | msg | ||
) |
Definition at line 120 of file lo-sysdep.cc.
References dir_entry::close(), dirname(), dir_entry::error(), dir_entry::read(), u8_from_wstring(), and u8_to_wstring().
Referenced by octave::Freaddir(), octave::genpath(), base_url_transfer::mput_directory(), and octave::sys::recursive_rmdir().
std::string getcwd | ( | ) |
Definition at line 72 of file lo-sysdep.cc.
References free(), octave_getcwd_wrapper(), and u8_from_wstring().
Referenced by octave_getcwd_wrapper().
std::string getenv_wrapper | ( | const std::string & | name | ) |
Definition at line 685 of file lo-sysdep.cc.
References u8_from_wstring(), and u8_to_wstring().
std::ifstream ifstream | ( | const std::string & | name, |
const std::ios::openmode | mode = std::ios::in |
||
) |
Definition at line 621 of file lo-sysdep.cc.
References u8_to_wstring().
Referenced by octave::F__ftp_mput__(), and base_url_transfer::mput_directory().
bool isenv_wrapper | ( | const std::string & | name | ) |
Definition at line 711 of file lo-sysdep.cc.
References u8_to_wstring().
Referenced by env::isenv().
std::ofstream ofstream | ( | const std::string & | name, |
const std::ios::openmode | mode = std::ios::out |
||
) |
Definition at line 635 of file lo-sysdep.cc.
References u8_to_wstring().
Referenced by load_save_system::dump_octave_core(), octave::F__ftp_mget__(), octave::Furlwrite(), base_url_transfer::mget_directory(), and diary_buf::sync().
void putenv_wrapper | ( | const std::string & | name, |
const std::string & | value | ||
) |
Definition at line 649 of file lo-sysdep.cc.
References len, malloc(), octave_putenv_wrapper(), and u8_to_wstring().
Referenced by env::putenv(), and unsetenv_wrapper().
bool same_file | ( | const std::string & | f, |
const std::string & | g | ||
) |
Definition at line 437 of file lo-sysdep.cc.
int system | ( | const std::string & | cmd_str | ) |
Definition at line 60 of file lo-sysdep.cc.
References u8_to_wstring().
std::string u8_from_wstring | ( | const std::wstring & | wchar_string | ) |
Definition at line 746 of file lo-sysdep.cc.
Referenced by octave::sys::canonicalize_file_name(), get_ASCII_filename(), get_dirlist(), getcwd(), getenv_wrapper(), base_tm::init(), and dir_entry::read().
std::wstring u8_to_wstring | ( | const std::string & | utf8_string | ) |
Definition at line 723 of file lo-sysdep.cc.
Referenced by file_time::file_time(), octave::sys::canonicalize_file_name(), dir_exists(), octave::drive_or_unc_share(), octave::F__open_with_system_app__(), file_exists(), fopen(), fstream(), get_ASCII_filename(), get_dirlist(), getenv_wrapper(), ifstream(), isenv_wrapper(), ofstream(), octave::popen(), putenv_wrapper(), dir_entry::read(), octave::sys::rename(), same_file(), system(), unsetenv_wrapper(), and windows_glob().
int unsetenv_wrapper | ( | const std::string & | name | ) |
Definition at line 698 of file lo-sysdep.cc.
References octave_unsetenv_wrapper(), putenv_wrapper(), and u8_to_wstring().
Referenced by octave::Funsetenv().