class fs.ResourceType[source]

Resource Types.

Positive values are reserved, negative values are implementation dependent.

Most filesystems will support only directory(1) and file(2). Other types exist to identify more exotic resource types supported by Linux filesystems.

block_special_file = 4

A block special file.

character = 3

A character file.

directory = 1

A directory.

fifo = 5

A first in first out file.

file = 2

A simple file.

socket = 6

A socket.

A symlink.

unknown = 0

Unknown resource type, used if the filesystem is unable to tell what the resource is.

class fs.Seek[source]

Constants used by file.seek.

These match os.SEEK_CUR, os.SEEK_END, and os.SEEK_SET from the standard library.

current = 1

Seek from the current file position.

end = 2

Seek from the end of the file.

set = 0

Seek from the start of the file.