def __init__(self, file, start):
assert hasattr(file, 'read') and hasattr(file, 'tell') and hasattr(file, 'seek')
assert isinstance(start, int)
self.file, self.start = file, start
self.total_len = total_len(file)
self.len = self.total_len - start
io.IOBase.__init__(self)
try:
self.seek(0)
except:
pass
评论列表
文章目录