|
string | Utils::get_basename (string_view path) |
|
string | Utils::get_filename (string_view path) |
|
string | Utils::get_extension (string_view path) |
|
bool | Utils::get_environment (string_view ename, string &res) |
| Fetches the value of an environment variable.
|
|
void | Utils::set_environment (string_view ename, string_view newval, bool overwrite) |
| Sets the value of an environment variable.
|
|
void | Utils::get_MAC_address (std::map< string, string > &addr) |
| Retrieves the MAC addresses of network interfaces.
|
|
string | Utils::get_host_name () |
| Retrieves the hostname of the system.
|
|
void | Utils::get_IP_address (std::vector< string > &addr) |
| Fetches the IP addresses of the system.
|
|
string | Utils::get_user_name () |
| Retrieves the username of the current user.
|
|
string | Utils::get_home_directory () |
| Retrieves the home directory of the current user.
|
|
string | Utils::get_executable_path_name () |
| Retrieves the full path to the current executable.
|
|
bool | Utils::check_if_file_exists (string_view fname) |
| Checks if a file exists.
|
|
bool | Utils::check_if_dir_exists (string_view dirname) |
| Checks if a directory exists.
|
|
bool | Utils::make_directory (string_view dirname, unsigned mode=0777) |
| Creates a directory if it does not exist.
|
|
string | Utils::get_date () |
|
string | Utils::get_day_time () |
|
string | Utils::get_day_time_and_date () |
|
string | Utils::get_log_date_time () |
|
template<typename T_int, typename T_real> |
void | Utils::search_interval (T_int npts, T_real const X[], T_real &x, T_int &last_interval, bool closed, bool can_extend) |
|
template<typename T_int, typename T_real> |
void | Utils::searchInterval (T_int npts, T_real const X[], T_real &x, T_int &last_interval, bool closed, bool can_extend) |
|
string | Utils::progress_bar (double const progress, int const width) |
| Generates a text-based progress bar as a string.
|
|
void | Utils::progress_bar (ostream_type &s, double const progress, int const width, string_view const msg) |
| Outputs a text-based progress bar to the specified output stream.
|
|
void | Utils::progress_bar2 (ostream_type &s, double const progress, int const width, string_view const msg) |
| Outputs an enhanced text-based progress bar to the specified output stream.
|
|