FileStats

The FileStats class details information about a file on disk. FileStats objects are returned by the FileSystem class method nova.fs.stat().

Properties

atime

The last access time of the file’s content, as a Date object.

This property is readonly.

ctime

The last modification time of the file’s metadata, as a Date object.

Note: This is not the creation date of the file. Use the birthtime property for that. On Unix systems, the “ctime” represents the last time the file’s metadata was modified, not necessarily when the file was created on disk.

This property is readonly.

mtime

The last modification time of the file’s content, as a Date object.

This property is readonly.

birthtime

The creation time of the file, as a Date object.

This property is readonly.

size

The size of the file, in bytes, as a number.

This property is readonly.

Methods

isFile()

Returns true if the path represents a regular file.

isDirectory()

Returns true if the path represents a directory.

Returns true if the path represents a symbolic link.