listDir.File: Gets the file names in the directory

Description Usage Arguments Value Author(s) See Also

Description

Gets the file names in the directory. If the File object is not a directory NULL is returned.

Contrary to list.files(), this method guarantees to work recursive. Moreover, when subdirectories are processed recursively, directory names are also returned.

Usage

1
2
## S3 method for class 'File'
listDir(this, pattern=NULL, recursive=FALSE, private=FALSE, full.names=FALSE, ...)

Arguments

pattern

Pattern passed to internal list.files(). This is an alternative to argument filter.

recursive

If TRUE, subdirectories are recursively processed, otherwise not.

private

If TRUE, also files starting with a period are returned.

full.names

If TRUE, the full path names are returned.

...

Not used.

Value

Returns a vector of file names. If the File object is not a directory NULL is returned.

Author(s)

Henrik Bengtsson (http://www.braju.com/R/)

See Also

For more information about pathname filters, see interface To get a list of File objects, instead of just the file names, see *listFiles(). Internally list.files() is used. For more information see File.


HenrikBengtsson/R.io documentation built on May 6, 2019, 11:54 p.m.