tarfile.ExFileObject

class tarfile.ExFileObject(tarfile, tarinfo)[source]

File-like object for reading an archive member. Is returned by TarFile.extractfile().

Methods

__format__ default object formatter
__init__(tarfile, tarinfo)
__iter__() Get an iterator over the file’s lines.
__new__((S, ...)
__reduce__ helper for pickle
__reduce_ex__ helper for pickle
__sizeof__(() -> int) size of object in memory, in bytes
__subclasshook__ Abstract classes can override this to customize issubclass().
close() Close the file object.
read([size]) Read at most size bytes from the file.
readline([size]) Read one entire line from the file.
readlines() Return a list with all remaining lines.
seek(pos[, whence]) Seek to a position in the file.
tell() Return the current file position.

Attributes

blocksize