os.Path.type
Returns the file type as a string.
Syntax
os.Path.type(
path STRING)
RETURNS STRING
- path is the path to file.
Usage
On UNIX™, this method follows symbolic links.
Use the os.Path.islink()
method to identify symbolic links.
The possible values returned by this method are:
file
: the file is a regular filedirectory
: the file is a directorysocket
: the file is a socketfifo
: the file is a fifoblock
: the file is a block devicechar
: the file is a character device