FORCES
FORtran lib for Comp. Env. Sys.
|
Path and directory management. More...
Go to the source code of this file.
Data Types | |
interface | mo_os::path_join |
Join given path segments with separator if needed. More... | |
Modules | |
module | mo_os |
Path and directory management. | |
Functions/Subroutines | |
subroutine, public | mo_os::get_cwd (path, status, verbose, raise) |
Get the current working directory. | |
subroutine, public | mo_os::change_dir (path, status, verbose, raise) |
Change current working directory. | |
subroutine, public | mo_os::check_path_exists (path, answer, verbose, raise) |
Checks whether a given path exists. | |
subroutine, public | mo_os::check_path_isfile (path, answer, verbose, raise) |
Checks whether a given path exists and describes a file. | |
subroutine, public | mo_os::check_path_isdir (path, answer, verbose, raise) |
Checks whether a given path exists and describes a directory. | |
logical function, public | mo_os::path_exists (path) |
Return .true. if path refers to an existing path. | |
logical function, public | mo_os::path_isfile (path) |
Return .true. if path is an existing regular file. | |
logical function, public | mo_os::path_isdir (path) |
Return .true. if path is an existing directory. | |
logical function, public | mo_os::path_isabs (path) |
Return .true. if path is an absolute pathname. | |
logical function, public | mo_os::path_isroot (path) |
Return .true. if path is root ('/' or '//' or '///' and so on). | |
subroutine, public | mo_os::path_splitext (path, root, ext) |
Splitting the path into root and ext. | |
subroutine, public | mo_os::path_split (path, head, tail) |
Splitting the path into head and tail. | |
subroutine, public | mo_os::path_parts (path, parts) |
Splitting the path into its components. | |
character(:) function, allocatable, public | mo_os::path_dirname (path) |
Return the directory name of pathname path. | |
character(:) function, allocatable, public | mo_os::path_basename (path) |
Return the base name of pathname path. | |
character(:) function, allocatable, public | mo_os::path_root (path) |
Return the path without its suffix. | |
character(:) function, allocatable, public | mo_os::path_ext (path) |
Return the file extension of the final path component. | |
character(:) function, allocatable, public | mo_os::path_stem (path) |
Return the final path component without its suffix. | |
character(:) function, allocatable, public | mo_os::path_as_posix (path) |
Return the string representation of the path with forward (/) slashes. | |
character(:) function, allocatable, public | mo_os::path_normpath (path) |
Normalize a pathname by collapsing redundant separators and up-level references. | |
character(:) function, allocatable, public | mo_os::path_abspath (path) |
Return a normalized absolutized version of the given path. | |
character(:) function, allocatable | mo_os::path_join_char (p1, p2) |
Join two path segments with separator if needed. | |
character(:) function, allocatable | mo_os::path_join_char_opt (p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16) |
Join given path segments with separator if needed. | |
character(:) function, allocatable | mo_os::path_join_arr (paths) |
Join given path segments with separator if needed. | |
subroutine | mo_os::path_msg (msg, path, verbose, raise) |
subroutine | mo_os::pop (arr) |
character array pop | |
Variables | |
character(len=*), parameter, public | mo_os::curdir = '.' |
The constant string used by the operating system to refer to the current directory. | |
character(len=*), parameter, public | mo_os::pardir = '..' |
The constant string used by the operating system to refer to the parent directory. | |
character(len=*), parameter, public | mo_os::sep = '/' |
The character used by the operating system to separate pathname components. | |
character(len=*), parameter, public | mo_os::extsep = '.' |
The character which separates the base filename from the extension. | |
character(len=*), parameter, public | mo_os::linesep = '\n' |
The string used to separate (or, rather, terminate) lines on the current platform. | |
character(len=*), parameter, public | mo_os::devnull = '/dev/null' |
The file path of the null device. | |
integer(i4), save, public | mo_os::max_path_comp_len = 256_i4 |
Maximum length of a path component (folder/file names). | |
integer(i4), save, public | mo_os::max_path_len = 4096_i4 |
Maximum length of a path (16 max. length components). | |
Path and directory management.
Path handling and existence checks for files and directories.
COPYING
and COPYING.LESSER
provided with this software. The complete GNU license text can also be found at http://www.gnu.org/licenses/. Definition in file mo_os.F90.