Pathname -This field is required. It specifies a file name that includes its directory and drive.
Mode – This field is also required. The mode can be append, Binary, output, input or random. The default mode is random.
Access – This parameter is optional. It specifies operations that are permitted on an open file. It can be read, write or read write.
Lock – It’s an optional parameter. It specifies the operations such as shared, lock read, lock write and lock read-write which are restricted on an open file.