sdk/python/File System/PyFileinput
File System

PyFileinput

Python stdlib module — fileinput. Auto-indexed from CDN. Method-level security roles have not been annotated; rule writers should inspect the source before use.

Other Methods

.close()Neutral
#
Signature
close()

Close the sequence.

.filelineno()Neutral
#
Signature
filelineno()

Return the line number in the current file. Before the first line

.filename()Neutral
#
Signature
filename()

Return the name of the file currently being read.

.fileno()Neutral
#
Signature
fileno()

Return the file number of the current file. When no file is currently

.hook_compressed()Neutral
#
Signature
hook_compressed(filename, mode, encoding, errors)

hook_compressed function.

.hook_encoded()Neutral
#
Signature
hook_encoded(encoding, errors)

hook_encoded function.

.input()Neutral
#
Signature
input(files, inplace, backup, mode, openhook, encoding, errors)

Return an instance of the FileInput class, which can be iterated.

.isfirstline()Neutral
#
Signature
isfirstline()

Returns true the line just read is the first line of its file,

.isstdin()Neutral
#
Signature
isstdin()

Returns true if the last line was read from sys.stdin,

.lineno()Neutral
#
Signature
lineno()

Return the cumulative line number of the line that has just been read.

Fully-Qualified Names

FQNField
fileinputfqns[0]

Wrong FQN → 0 findings. Verify with: change fqns to garbage → must produce 0 results.

Import

rule.py
import fileinput