Eclipse behavior for
Function DIRECTORY
Syntax:
Eclipse defines the following additional &KEY argument for the directory function:
links -- a symbol. The default is T.
if-does-not-exist -- one of :ERROR,
:CREATE, or NIL. The default is
:ERROR.
Description:
Links specifies whether file system symbolic links should be followed during resolution to truenames:
:ONCE, such links are
followed once, and the file or directory pathname that the link points
to is returned.
If-does-not-exist specifies the action to be taken if a directory component of the filespec being scanned does not exist in the file system:
:ERROR (the
default), an error of type file-error is signaled.
:CREATE,
missing directories are created as though by
ensure-directories-exist. Directory then procedes
normally, returing either NIL if a specific file was
requested, or a list of the directory name that was requested.
NIL,
directory returns NIL.
See Also:
Eclipse Pathnames, and the Packages section of "Eclipse-Defined ANSI Features".
Notes:
The package of the links and if-does-not-exist
&key designators is the KEYWORD package.
Note that, like all file system operations, the pathname argument to
directory is merged with *default-pathname-defaults*
and, if necessary, translated to a physical pathname. The default
value for *default-pathname-defaults* has a version of
:newest, and the default value for the
default-version argument to merge-pathnames is
:newest, so if the version is not specified in the
pathname argument to directory, only the newest versions will
be returned. Of course, all versions can be returned by explicitly
providing a wild version component in the pathname argument to
directory.