is_dir

Gamma: Version 4.0
Prev |  | Next

# `is_dir`

`is_dir` -- determines if a file is a directory.

## Syntax

    is_dir (path)

## Arguments

`path`

  A character string defining a relative or absolute file path in this file system.

## Returns

t if the named file exists and is a directory, otherwise nil.

## Description

This function checks if a file is a directory. Relative file paths are relative to the current working directory.

## Example

        Gamma> is_dir("/home/robert/w/devel/lisp");
        t
        Gamma> is_dir("../../doc");
        t
        Gamma> is_dir("doc");
        nil
        Gamma>

See the Common: the Data Directory of the Controller Functions chapter (Tutorial Two) in the Cogent Tools Demo and Tutorials book for an example of this function used in context.

## See Also

`is_file`

Prev | Home | Next
`is_busy` | Up | `is_file`

Copyright 1995-2002 by Cogent Real-Time Systems, Inc.