fileinput.FileInput¶
-
class
fileinput.FileInput([files[, inplace[, backup[, bufsize[, mode[, openhook]]]]]])[source]¶ Class FileInput is the implementation of the module; its methods filename(), lineno(), fileline(), isfirstline(), isstdin(), fileno(), nextfile() and close() correspond to the functions of the same name in the module. In addition it has a readline() method which returns the next input line, and a __getitem__() method which implements the sequence behavior. The sequence must be accessed in strictly sequential order; random access and readline() cannot be mixed.