[UP]


Manual Reference Pages  - system_dir (3)

NAME

system_dir(3f) - [M_io] return filenames in a directory matching specified wildcard string (LICENSE:PD)

CONTENTS

Synopsis
Description
Options
Returns
Example
Author
License

SYNOPSIS

function system_dir(directory,pattern)

   character(len=*),intent(in),optional  :: directory
   character(len=*),intent(in),optional  :: pattern
   character(len=:),allocatable          :: system_dir(:)

DESCRIPTION

returns an array of filenames in the specified directory matching the wildcard string (which defaults to "*").

OPTIONS

DIRECTORY
  name of directory to match filenames in. Defaults to ".".
PATTERN
  wildcard string matching the rules of the matchw(3f) function. Basically
o "*" matches anything
o "?" matches any single character

RETURNS

system_dir
  An array right-padded to the length of the longest filename. Note that this means filenames actually containing trailing spaces in their names may be incorrect.

EXAMPLE

Sample program:

   program demo_system_dir
   use M_system, only : system_dir
   implicit none
      write(*, ’(a)’)system_dir(pattern=’*.f90’)
   end program demo_system_dir

AUTHOR

John S. Urban

LICENSE

Public Domain


system_dir (3) March 11, 2021
Generated by manServer 1.08 from 2ab0cada-a810-4e14-aa11-a94dc6b17e35 using man macros.