file*¶
close¶
Close file
.
flush¶
Saves any written data to file
.
lines¶
...(param):
| "n" -- Reads a numeral and returns it as number.
| "a" -- Reads the whole file.
-> "l" -- Reads the next line skipping the end of line.
| "L" -- Reads the next line keeping the end of line.
read¶
Reads the file
, according to the given formats, which specify what to read.
...(param):
| "n" -- Reads a numeral and returns it as number.
| "a" -- Reads the whole file.
-> "l" -- Reads the next line skipping the end of line.
| "L" -- Reads the next line keeping the end of line.
seek¶
(method) file*:seek(whence?: "cur"|"end"|"set", offset?: integer)
-> offset: integer
2. errmsg: string?
Sets and gets the file position, measured from the beginning of the file.
whence:
| "set" -- Base is beginning of the file.
-> "cur" -- Base is current position.
| "end" -- Base is end of file.
setvbuf¶
Sets the buffering mode for an output file.
mode:
| "no" -- Output operation appears immediately.
| "full" -- Performed only when the buffer is full.
| "line" -- Buffered until a newline is output.
write¶
Writes the value of each of its arguments to file
.